mirror of
https://github.com/littensy/charm.git
synced 2026-10-20 17:51:37 +00:00
test: use lute for tests
This commit is contained in:
parent
72b290219d
commit
a20ee3698a
47 changed files with 190 additions and 236 deletions
6
.lute/build.luau
Normal file
6
.lute/build.luau
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
local fs = require("@std/fs")
|
||||
local process = require("@lute/process")
|
||||
|
||||
fs.createdirectory("build")
|
||||
|
||||
process.run({ "rojo", "build", "--output=build/charm.rbxm" }, { stdio = "inherit" })
|
||||
30
.lute/check.luau
Normal file
30
.lute/check.luau
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
local fs = require("@std/fs")
|
||||
local net = require("@lute/net")
|
||||
local process = require("@lute/process")
|
||||
|
||||
process.run({ "rojo", "sourcemap", "--output=sourcemap.json" }, { stdio = "inherit" })
|
||||
|
||||
fs.writestringtofile(
|
||||
"roblox.d.luau",
|
||||
net.request("https://luau-lsp.pages.dev/globalTypes.None.d.luau", { method = "GET" }).body
|
||||
)
|
||||
|
||||
process.run({
|
||||
"luau-lsp",
|
||||
"analyze",
|
||||
"--sourcemap=sourcemap.json",
|
||||
"--ignore=**/node_modules/**",
|
||||
"--base-luaurc=.luaurc",
|
||||
"--defs=roblox.d.luau",
|
||||
"packages",
|
||||
"tests",
|
||||
"benches",
|
||||
}, { stdio = "inherit" })
|
||||
|
||||
fs.remove("roblox.d.luau")
|
||||
|
||||
process.run({ "selene", "packages", "tests", "benches" }, { stdio = "inherit" })
|
||||
|
||||
process.run({ "stylua", "--check", "packages", "tests", "benches" }, { stdio = "inherit" })
|
||||
|
||||
process.run({ "pnpm", "eslint", "packages" }, { stdio = "inherit" })
|
||||
1
.lute/test.luau
Normal file
1
.lute/test.luau
Normal file
|
|
@ -0,0 +1 @@
|
|||
(require)("../tests/run.server")
|
||||
Loading…
Add table
Add a link
Reference in a new issue