diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2022-05-23 15:22:16 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2022-05-23 15:22:16 -0700 |
commit | c9434e4f175f599e038a3e28e8340825697543d0 (patch) | |
tree | ca2553d3162d2c8e153ee6242b268200d5610b55 /app.lua | |
parent | 254ae7ad99777d56e48379ef3d1e90c189f7e321 (diff) | |
download | text.love-c9434e4f175f599e038a3e28e8340825697543d0.tar.gz |
snapshot
Why the fuck is this so fucking hard?
Diffstat (limited to 'app.lua')
-rw-r--r-- | app.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/app.lua b/app.lua index bb463b7..4b3f1ad 100644 --- a/app.lua +++ b/app.lua @@ -199,10 +199,17 @@ function App.screen.check(y, expected_contents, msg) end function App.run_tests() + local sorted_names = {} for name,binding in pairs(_G) do if name:find('test_') == 1 then + table.insert(sorted_names, name) + end + end + table.sort(sorted_names) + for _,name in ipairs(sorted_names) do + if name:find('test_') == 1 then App.initialize_for_test() - binding() + _G[name]() end end print() |