Skip to content

Commit

Permalink
refactor: use vim.tbl_isempty (#67)
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrikaverpil authored Jun 29, 2024
1 parent 665e28b commit 3a8ea7e
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 14 deletions.
1 change: 0 additions & 1 deletion lua/neotest-golang/results_dir.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ local async = require("neotest.async")
local options = require("neotest-golang.options")
local convert = require("neotest-golang.convert")
local json = require("neotest-golang.json")
local utils = require("neotest-golang.utils")

--- @class TestData
--- @field status neotest.ResultStatus
Expand Down
4 changes: 1 addition & 3 deletions lua/neotest-golang/runspec_file.lua
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
local utils = require("neotest-golang.utils")

local M = {}

--- Build runspec for a directory.
--- @param pos neotest.Position
--- @param tree neotest.Tree
--- @return neotest.RunSpec | neotest.RunSpec[] | nil
function M.build(pos, tree)
if utils.table_is_empty(tree:children()) then
if vim.tbl_isempty(tree:children()) then
--- Runspec designed for files that contain no tests.
--- @type neotest.RunSpec
local run_spec = {
Expand Down
10 changes: 0 additions & 10 deletions lua/neotest-golang/utils.lua

This file was deleted.

0 comments on commit 3a8ea7e

Please sign in to comment.