Skip to content

Commit

Permalink
test: should throw when file does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
rcasia committed Oct 27, 2024
1 parent f852f77 commit b73c4fa
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/util/resolve_qualified_name_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,11 @@ describe("resolve_qualified_name", function()
assert.are.same(case.expected, result)
end)
end

a.it("it should error when file does not exist", function()
local bad_example_filepath = "some-fake-filename"
assert.has_error(function()
resolve_qualified_name(bad_example_filepath)
end, string.format("file does not exist: %s", bad_example_filepath))
end)
end)

0 comments on commit b73c4fa

Please sign in to comment.