jest-roblox-assassin 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -10,12 +10,13 @@ jestrbx is a CLI tool for running Jest-style tests against Roblox places, wrappi
10
10
  - Integrates with roblox-ts, Rojo, and standard TypeScript workflows
11
11
  - Handles source mapping for .ts, .tsx, .lua, and .luau files
12
12
  - Filters tests by name or path
13
+ - Supports coverage reporting through `--coverage` (see below for setup)
13
14
  - Supports parallel execution through `--maxWorkers`
14
15
 
15
16
  ## Getting Started
16
17
 
17
18
  ### Prerequisites
18
- - Node.js (v16+ recommended)
19
+ - Node.js v22+ (recommended v24+)
19
20
  - roblox-ts and Rojo (for TypeScript workflows)
20
21
 
21
22
  ### Installation
@@ -32,25 +33,34 @@ Run tests against a Roblox place file:
32
33
  npx jestrbx --place path/to/place.rbxl
33
34
  ```
34
35
 
35
- #### Common CLI Options
36
- - `--place <file>`: Path to the Roblox place file (required)
37
- - `--project <dir>`: Path to the Rojo project file (optional)
38
- - `--config <file>`: Path to a Jest config file. This is usually used to specify reporter options (optional)
39
- - `--testNamePattern <pattern>`: Filter tests by name
40
- - `--reporters <reporter>`: Use custom or built-in reporters
41
- - `--maxWorkers <num>`: Number of worker threads to use for parallel test execution
42
-
43
36
  For a full list of options, run:
44
37
 
45
38
  ```sh
46
39
  npx jestrbx --help
47
40
  ```
48
41
 
42
+ ### Cloud Execution
43
+ It's recommended to run tests through Roblox Open Cloud. Create a `.env` file with a `ROBLOSECURITY` field:
44
+ ```
45
+ ROBLOSECURITY=your_roblosecurity_cookie_here
46
+ # or if you want to load balance across multiple accounts:
47
+ ROBLOSECURITY=cookie1,cookie2,cookie3
48
+ ```
49
+ More information about setting up the `ROBLOSECURITY` variable can be found here: https://github.com/Unreal-Works/roblox-luau-execute
50
+
51
+ ### Coverage
52
+ Coverage reporting requires a valid coverage instrumentation library:
53
+ - Wally: https://wally.run/package/evilbocchi/roblox-coverage
54
+ - roblox-ts: `npm i @rbxts/coverage`
55
+
56
+ To enable coverage reporting, use the `--coverage` flag:
57
+ ```sh
58
+ npx jestrbx --place path/to/place.rbxl --coverage
59
+ ```
60
+
61
+
49
62
  ### Example Project
50
- See the `demo/` directory for a sample roblox-ts project with Jest specs:
51
- - `demo/src/jest.config.ts`: Jest config
52
- - `demo/src/setup.luau`: Setup script
53
- - `demo/src/__tests__/`: Test specs
63
+ See the `demo/` directory for a sample roblox-ts project with Jest tests configured.
54
64
 
55
65
  Build and test with:
56
66
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jest-roblox-assassin",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "Delightful Roblox testing.",
5
5
  "license": "MIT",
6
6
  "author": "evilbocchi",
@@ -10,27 +10,31 @@
10
10
  "jestrbx": "src/cli.js"
11
11
  },
12
12
  "repository": {
13
- "url": "https://github.com/Unreal-Works/jest-roblox-assassin.git",
13
+ "url": "git+https://github.com/Unreal-Works/jest-roblox-assassin.git",
14
14
  "type": "git"
15
15
  },
16
16
  "scripts": {
17
- "test": "vitest run",
18
- "test:watch": "vitest",
19
- "test:ui": "vitest --ui",
20
- "test:coverage": "vitest run --coverage",
17
+ "test": "node --experimental-vm-modules node_modules/jest/bin/jest.js",
18
+ "test:coverage": "node --experimental-vm-modules node_modules/jest/bin/jest.js --coverage",
19
+ "build:demo": "cd demo && npm install && npm run build",
21
20
  "demo": "cd demo && npm run test"
22
21
  },
23
22
  "dependencies": {
24
23
  "@jest/reporters": "^30.2.0",
25
24
  "chalk": "^5.6.2",
26
- "commander": "^14.0.2",
27
- "rbxluau": "^1.7.0"
25
+ "chokidar": "^4.0.1",
26
+ "istanbul-lib-coverage": "^3.2.2",
27
+ "istanbul-lib-report": "^3.0.1",
28
+ "istanbul-reports": "^3.2.0",
29
+ "rbxluau": "^2.0.1",
30
+ "yargs": "^18.0.0"
28
31
  },
29
32
  "devDependencies": {
30
33
  "@types/node": "^25.0.3",
31
- "@vitest/coverage-v8": "^4.0.16",
32
- "@vitest/ui": "^4.0.16",
33
34
  "dotenv": "^17.2.3",
34
- "vitest": "^4.0.16"
35
- }
35
+ "jest": "^30.2.0"
36
+ },
37
+ "files": [
38
+ "src"
39
+ ]
36
40
  }
package/src/cache.js CHANGED
@@ -17,3 +17,4 @@ export function ensureCache() {
17
17
  }
18
18
  return CACHE_FOLDER_PATH;
19
19
  }
20
+