diff options
-rw-r--r-- | .github/workflows/test.yml | 21 | ||||
-rw-r--r-- | src/nvim/marktree.c | 3 | ||||
-rw-r--r-- | test/functional/api/version_spec.lua | 2 | ||||
-rw-r--r-- | test/functional/core/main_spec.lua | 4 | ||||
-rw-r--r-- | test/functional/lua/fs_spec.lua | 12 |
5 files changed, 23 insertions, 19 deletions
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0885efddd5..c7802d2210 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -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 -C test/old/testdir NVIM_PRG=$(realpath build)/bin/nvim + + - if: ${{ matrix.test != 'oldtest' }} + name: ${{ matrix.test }} timeout-minutes: 20 - run: make ${{ matrix.test }} + 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 diff --git a/src/nvim/marktree.c b/src/nvim/marktree.c index 555fef5bbd..5ccd4fd45d 100644 --- a/src/nvim/marktree.c +++ b/src/nvim/marktree.c @@ -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__); \ diff --git a/test/functional/api/version_spec.lua b/test/functional/api/version_spec.lua index 72b5e307ee..68c4ef7503 100644 --- a/test/functional/api/version_spec.lua +++ b/test/functional/api/version_spec.lua @@ -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) diff --git a/test/functional/core/main_spec.lua b/test/functional/core/main_spec.lua index a445423efc..3b7cefb89f 100644 --- a/test/functional/core/main_spec.lua +++ b/test/functional/core/main_spec.lua @@ -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 diff --git a/test/functional/lua/fs_spec.lua b/test/functional/lua/fs_spec.lua index f0d49205e7..89f6ad6a0e 100644 --- a/test/functional/lua/fs_spec.lua +++ b/test/functional/lua/fs_spec.lua @@ -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) |