aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2022-09-09 00:12:42 +0200
committerGitHub <noreply@github.com>2022-09-08 15:12:42 -0700
commit2d6735d8cecc587eb5549f65260ee9ddeb8e1d78 (patch)
tree3780a53f31117479b1be92d2c5585734626fa21b /test
parentd6233cbcdc3ace30c87676131d25fd2522a7838c (diff)
downloadrneovim-2d6735d8cecc587eb5549f65260ee9ddeb8e1d78.tar.gz
rneovim-2d6735d8cecc587eb5549f65260ee9ddeb8e1d78.tar.bz2
rneovim-2d6735d8cecc587eb5549f65260ee9ddeb8e1d78.zip
ci: move BSD jobs from sourcehut to Cirrus CI #19616
dispatch.sr.ht is being deprecated, meaning that using sourcehut CI won't be possible (see https://github.com/neovim/neovim/issues/19609). Since Github Actions doesn't provide any BSD runners an external service is required and Cirrus CI seems like a good replacement for sourcehut. Initially experimented with using FreeBSD and OpenBSD virtual machines in GitHub Actions, but Cirrus has been a much better fit with better performance, logs and overall experience. Failing tests are automatically skipped on FreeBSD regardless if it's on CI or not. Ideally these tests should only be skipped in CI with the help of `isCI` helper function. Unfortunately, the tests don't recognize the environment variable CIRRUS_CI even if it's set manually. This workaround is good enough for the time being, but we might want to only skip tests when using the CI (or even better, fix the failing tests). Closes: https://github.com/neovim/neovim/issues/19609
Diffstat (limited to 'test')
-rw-r--r--test/functional/api/server_notifications_spec.lua4
-rw-r--r--test/functional/core/fileio_spec.lua7
-rw-r--r--test/functional/ex_cmds/write_spec.lua7
-rw-r--r--test/functional/terminal/ex_terminal_spec.lua4
-rw-r--r--test/helpers.lua5
5 files changed, 24 insertions, 3 deletions
diff --git a/test/functional/api/server_notifications_spec.lua b/test/functional/api/server_notifications_spec.lua
index 1c00f001ff..1c554b05a3 100644
--- a/test/functional/api/server_notifications_spec.lua
+++ b/test/functional/api/server_notifications_spec.lua
@@ -7,6 +7,7 @@ local exec_lua = helpers.exec_lua
local retry = helpers.retry
local isCI = helpers.isCI
local assert_alive = helpers.assert_alive
+local uname = helpers.uname
describe('notify', function()
local channel
@@ -78,6 +79,9 @@ describe('notify', function()
end)
it('cancels stale events on channel close', function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
if isCI() then
pending('hangs on CI #14083 #15251')
return
diff --git a/test/functional/core/fileio_spec.lua b/test/functional/core/fileio_spec.lua
index a4d22685e8..e71131dcf8 100644
--- a/test/functional/core/fileio_spec.lua
+++ b/test/functional/core/fileio_spec.lua
@@ -23,6 +23,7 @@ local iswin = helpers.iswin
local assert_alive = helpers.assert_alive
local expect_exit = helpers.expect_exit
local write_file = helpers.write_file
+local uname = helpers.uname
describe('fileio', function()
before_each(function()
@@ -83,6 +84,9 @@ describe('fileio', function()
end)
it('backup #9709', function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
clear({ args={ '-i', 'Xtest_startup_shada',
'--cmd', 'set directory=Xtest_startup_swapdir' } })
@@ -102,6 +106,9 @@ describe('fileio', function()
end)
it('backup with full path #11214', function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
clear()
mkdir('Xtest_backupdir')
command('set backup')
diff --git a/test/functional/ex_cmds/write_spec.lua b/test/functional/ex_cmds/write_spec.lua
index 32fe397c03..14035a4341 100644
--- a/test/functional/ex_cmds/write_spec.lua
+++ b/test/functional/ex_cmds/write_spec.lua
@@ -9,6 +9,7 @@ local feed_command = helpers.feed_command
local funcs = helpers.funcs
local meths = helpers.meths
local iswin = helpers.iswin
+local uname = helpers.uname
local fname = 'Xtest-functional-ex_cmds-write'
local fname_bak = fname .. '~'
@@ -52,6 +53,9 @@ describe(':write', function()
end)
it('&backupcopy=no replaces symlink with new file', function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
command('set backupcopy=no')
write_file('test_bkc_file.txt', 'content0')
if iswin() then
@@ -91,6 +95,9 @@ describe(':write', function()
end)
it('errors out correctly', function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
command('let $HOME=""')
eq(funcs.fnamemodify('.', ':p:h'), funcs.fnamemodify('.', ':p:h:~'))
-- Message from check_overwrite
diff --git a/test/functional/terminal/ex_terminal_spec.lua b/test/functional/terminal/ex_terminal_spec.lua
index 23b69319f0..36f9f90143 100644
--- a/test/functional/terminal/ex_terminal_spec.lua
+++ b/test/functional/terminal/ex_terminal_spec.lua
@@ -10,6 +10,7 @@ local retry = helpers.retry
local ok = helpers.ok
local iswin = helpers.iswin
local command = helpers.command
+local uname = helpers.uname
describe(':terminal', function()
local screen
@@ -45,6 +46,9 @@ describe(':terminal', function()
end)
it("reads output buffer on terminal reporting #4151", function()
+ if uname() == 'freebsd' then
+ pending('Failing FreeBSD test')
+ end
if helpers.pending_win32(pending) then return end
if iswin() then
feed_command([[terminal powershell -NoProfile -NoLogo -Command Write-Host -NoNewline "\"$([char]27)[6n\""; Start-Sleep -Milliseconds 500 ]])
diff --git a/test/helpers.lua b/test/helpers.lua
index 7ec9beea92..499b91488b 100644
--- a/test/helpers.lua
+++ b/test/helpers.lua
@@ -790,10 +790,9 @@ end
function module.isCI(name)
local any = (name == nil)
- assert(any or name == 'sourcehut' or name == 'github')
- local sh = ((any or name == 'sourcehut') and nil ~= os.getenv('SOURCEHUT'))
+ assert(any or name == 'github')
local gh = ((any or name == 'github') and nil ~= os.getenv('GITHUB_ACTIONS'))
- return sh or gh
+ return gh
end