fix(test): proper picking
This commit is contained in:
parent
16ddbb5b4e
commit
0a39a2e6a2
2 changed files with 5 additions and 0 deletions
|
|
@ -266,6 +266,7 @@ function M.setup(user_config)
|
||||||
error('No language configurations found')
|
error('No language configurations found')
|
||||||
end
|
end
|
||||||
|
|
||||||
|
table.sort(available_langs)
|
||||||
contest_config.default_language = available_langs[1]
|
contest_config.default_language = available_langs[1]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -194,6 +194,10 @@ describe('cp.picker', function()
|
||||||
|
|
||||||
picker.setup_problem('codeforces', '1951', 'a')
|
picker.setup_problem('codeforces', '1951', 'a')
|
||||||
|
|
||||||
|
vim.wait(100, function()
|
||||||
|
return called_with ~= nil
|
||||||
|
end)
|
||||||
|
|
||||||
assert.is_table(called_with)
|
assert.is_table(called_with)
|
||||||
assert.is_table(called_with.fargs)
|
assert.is_table(called_with.fargs)
|
||||||
assert.equals('codeforces', called_with.fargs[1])
|
assert.equals('codeforces', called_with.fargs[1])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue