-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test(actions): add test cases for 'actions' (#225)
- Loading branch information
1 parent
1801ed9
commit 0ff97f4
Showing
7 changed files
with
34 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
local cwd = vim.fn.getcwd() | ||
|
||
describe("gitlinker.actions", function() | ||
local assert_eq = assert.is_equal | ||
local assert_true = assert.is_true | ||
local assert_false = assert.is_false | ||
|
||
before_each(function() | ||
vim.api.nvim_command("cd " .. cwd) | ||
end) | ||
|
||
local actions = require("gitlinker.actions") | ||
require("gitlinker").setup() | ||
|
||
describe("[actions]", function() | ||
local URL = | ||
"https://github.com/linrongbin16/gitlinker.nvim/blob/1801ed9513fd4a1f0bff3440dcca7b0ea656a508/spec/gitlinker_spec.lua?plain=1#L3" | ||
it("clipboard", function() | ||
actions.clipboard(URL) | ||
end) | ||
it("system", function() | ||
actions.system(URL) | ||
end) | ||
end) | ||
end) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters