mirror of
https://github.com/neovim/neovim.git
synced 2024-12-19 10:45:16 -07:00
Merge #31358 fix test failures for release / tarball builds
This commit is contained in:
commit
6551e30630
21
.github/workflows/test.yml
vendored
21
.github/workflows/test.yml
vendored
@ -106,7 +106,7 @@ jobs:
|
||||
[
|
||||
{ runner: ubuntu-24.04, os: ubuntu, flavor: asan, cc: clang, flags: -D ENABLE_ASAN_UBSAN=ON },
|
||||
{ runner: ubuntu-24.04, os: ubuntu, flavor: tsan, cc: clang, flags: -D ENABLE_TSAN=ON },
|
||||
{ runner: ubuntu-24.04, os: ubuntu, cc: gcc },
|
||||
{ runner: ubuntu-24.04, os: ubuntu, flavor: release, cc: gcc, flags: -D CMAKE_BUILD_TYPE=Release },
|
||||
{ runner: macos-13, os: macos, flavor: intel, cc: clang, flags: -D CMAKE_FIND_FRAMEWORK=NEVER, deps_flags: -D CMAKE_FIND_FRAMEWORK=NEVER },
|
||||
{ runner: macos-15, os: macos, flavor: arm, cc: clang, flags: -D CMAKE_FIND_FRAMEWORK=NEVER, deps_flags: -D CMAKE_FIND_FRAMEWORK=NEVER },
|
||||
{ runner: ubuntu-24.04, os: ubuntu, flavor: puc-lua, cc: gcc, deps_flags: -D USE_BUNDLED_LUAJIT=OFF -D USE_BUNDLED_LUA=ON, flags: -D PREFER_LUA=ON },
|
||||
@ -145,6 +145,10 @@ jobs:
|
||||
sudo cpanm -n Neovim::Ext || cat "$HOME/.cpanm/build.log"
|
||||
perl -W -e 'use Neovim::Ext; print $Neovim::Ext::VERSION'
|
||||
|
||||
- name: Remove .git directory
|
||||
if: ${{ matrix.build.os == 'ubuntu' }}
|
||||
run: cmake -E rm -rf -- .git
|
||||
|
||||
- name: Build third-party deps
|
||||
run: |
|
||||
cmake -S cmake.deps --preset ci -D CMAKE_BUILD_TYPE=Debug ${{ matrix.build.deps_flags }}
|
||||
@ -155,9 +159,15 @@ jobs:
|
||||
cmake --preset ci -D CMAKE_BUILD_TYPE=Debug -D CMAKE_INSTALL_PREFIX:PATH=$INSTALL_PREFIX ${{ matrix.build.flags }}
|
||||
cmake --build build
|
||||
|
||||
- name: ${{ matrix.test }}
|
||||
- if: ${{ matrix.test == 'oldtest' }}
|
||||
name: ${{ matrix.test }}
|
||||
timeout-minutes: 20
|
||||
run: make ${{ matrix.test }}
|
||||
run: make -C test/old/testdir NVIM_PRG=$(realpath build)/bin/nvim
|
||||
|
||||
- if: ${{ matrix.test != 'oldtest' }}
|
||||
name: ${{ matrix.test }}
|
||||
timeout-minutes: 20
|
||||
run: cmake --build build --target ${{ matrix.test }}
|
||||
|
||||
- name: Install
|
||||
run: |
|
||||
@ -194,7 +204,7 @@ jobs:
|
||||
uses: ./.github/workflows/test_windows.yml
|
||||
|
||||
# This job tests the following things:
|
||||
# - Check if Release, MinSizeRel and RelWithDebInfo compiles correctly.
|
||||
# - Check if MinSizeRel and RelWithDebInfo compiles correctly.
|
||||
# - Test the above build types with the GCC compiler specifically.
|
||||
# Empirically the difference in warning levels between GCC and other
|
||||
# compilers is particularly big.
|
||||
@ -218,9 +228,6 @@ jobs:
|
||||
- name: Configure
|
||||
run: cmake --preset ci -G "Ninja Multi-Config"
|
||||
|
||||
- name: Release
|
||||
run: cmake --build build --config Release
|
||||
|
||||
- name: RelWithDebInfo
|
||||
run: cmake --build build --config RelWithDebInfo
|
||||
|
||||
|
@ -2330,7 +2330,6 @@ void marktree_check(MarkTree *b)
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifndef NDEBUG
|
||||
size_t marktree_check_node(MarkTree *b, MTNode *x, MTPos *last, bool *last_right,
|
||||
const uint32_t *meta_node_ref)
|
||||
{
|
||||
@ -2485,8 +2484,6 @@ bool mt_recurse_nodes_compare(MTNode *x, PMap(ptr_t) *checked)
|
||||
return true;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
// TODO(bfredl): kv_print
|
||||
#define GA_PUT(x) ga_concat(ga, (char *)(x))
|
||||
#define GA_PRINT(fmt, ...) snprintf(buf, sizeof(buf), fmt, __VA_ARGS__); \
|
||||
|
@ -43,7 +43,7 @@ describe("api_info()['version']", function()
|
||||
eq(0, fn.has('nvim-' .. major .. '.' .. minor .. '.' .. (patch + 1)))
|
||||
eq(0, fn.has('nvim-' .. major .. '.' .. (minor + 1) .. '.' .. patch))
|
||||
eq(0, fn.has('nvim-' .. (major + 1) .. '.' .. minor .. '.' .. patch))
|
||||
assert(build == nil or type(build) == 'string')
|
||||
assert(build == vim.NIL or type(build) == 'string')
|
||||
end)
|
||||
end)
|
||||
|
||||
|
@ -188,9 +188,9 @@ describe('command-line option', function()
|
||||
|
||||
it('nvim -v, :version', function()
|
||||
matches('Run ":verbose version"', fn.execute(':version'))
|
||||
matches('Compilation: .*Run :checkhealth', fn.execute(':verbose version'))
|
||||
matches('fall%-back for %$VIM: .*Run :checkhealth', fn.execute(':verbose version'))
|
||||
matches('Run "nvim %-V1 %-v"', fn.system({ nvim_prog_abs(), '-v' }))
|
||||
matches('Compilation: .*Run :checkhealth', fn.system({ nvim_prog_abs(), '-V1', '-v' }))
|
||||
matches('fall%-back for %$VIM: .*Run :checkhealth', fn.system({ nvim_prog_abs(), '-V1', '-v' }))
|
||||
end)
|
||||
|
||||
if is_os('win') then
|
||||
|
@ -273,14 +273,14 @@ describe('vim.fs', function()
|
||||
end)
|
||||
|
||||
it('works with a single marker', function()
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, '.git')]]))
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, 'CMakePresets.json')]]))
|
||||
end)
|
||||
|
||||
it('works with multiple markers', function()
|
||||
local bufnr = api.nvim_get_current_buf()
|
||||
eq(
|
||||
vim.fs.joinpath(test_source_path, 'test/functional/fixtures'),
|
||||
exec_lua([[return vim.fs.root(..., {'CMakeLists.txt', '.git'})]], bufnr)
|
||||
exec_lua([[return vim.fs.root(..., {'CMakeLists.txt', 'CMakePresets.json'})]], bufnr)
|
||||
)
|
||||
end)
|
||||
|
||||
@ -295,26 +295,26 @@ describe('vim.fs', function()
|
||||
end)
|
||||
|
||||
it('works with a filename argument', function()
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(..., '.git')]], nvim_prog))
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(..., 'CMakePresets.json')]], nvim_prog))
|
||||
end)
|
||||
|
||||
it('works with a relative path', function()
|
||||
eq(
|
||||
test_source_path,
|
||||
exec_lua([[return vim.fs.root(..., '.git')]], vim.fs.basename(nvim_prog))
|
||||
exec_lua([[return vim.fs.root(..., 'CMakePresets.json')]], vim.fs.basename(nvim_prog))
|
||||
)
|
||||
end)
|
||||
|
||||
it('uses cwd for unnamed buffers', function()
|
||||
command('new')
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, '.git')]]))
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, 'CMakePresets.json')]]))
|
||||
end)
|
||||
|
||||
it("uses cwd for buffers with non-empty 'buftype'", function()
|
||||
command('new')
|
||||
command('set buftype=nofile')
|
||||
command('file lua://')
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, '.git')]]))
|
||||
eq(test_source_path, exec_lua([[return vim.fs.root(0, 'CMakePresets.json')]]))
|
||||
end)
|
||||
end)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user