Documented code, got basic example working

This commit is contained in:
Isaac Clayton
2022-07-07 15:01:09 +02:00
parent 4ff9a6b1b5
commit 4003037ca8
7 changed files with 200 additions and 57 deletions
+22
View File
@@ -0,0 +1,22 @@
print("initializing plugin...")
query = [[(
(attribute_item
(meta_item
(identifier) @test)) @attribute
.
(function_item
name: (identifier) @name) @funciton
)]]
function run_test(name)
print('running test `' .. name .. '`:')
local command = 'cargo test -- ' .. name
local openPop = assert(io.popen(command, 'r'))
local output = openPop:read('*all')
openPop:close()
print('done running test')
return output
end
print("done initializing plugin.")