as-test 0.3.0 → 0.3.1

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.
@@ -19,9 +19,6 @@ jobs:
19
19
  - name: Install dependencies
20
20
  run: bun install
21
21
 
22
- - name: Build reporter
23
- run: bun run build:log
24
-
25
22
  - name: Build tests
26
23
  run: bun run pretest
27
24
 
package/CHANGELOG.md CHANGED
@@ -24,3 +24,4 @@ v0.2.0 - Fix mock -> mockFn artifacts
24
24
  v0.2.1 - Remove accidental logging
25
25
 
26
26
  v0.3.0 - Pass metadata through terminal - Support for multiple files - Better reporting - Timing for suites - Terminal utilities
27
+ v0.3.1 - Add screenshot of completed tests to readme
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  | _ || __| ___|_ _|| __|| __||_ _|
4
4
  | ||__ ||___| | | | __||__ | | |
5
5
  |__|__||_____| |_| |_____||_____| |_|
6
- v0.3.0
6
+ v0.3.1
7
7
  </pre>
8
8
  </h5>
9
9
 
@@ -133,6 +133,8 @@ Build and run it using as-test
133
133
  npm run test
134
134
  ```
135
135
 
136
+ <img src="https://raw.githubusercontent.com/JairusSW/as-test/main/assets/img/screenshot.png">
137
+
136
138
  <h6>
137
139
 
138
140
  ## Running
Binary file
package/bin/index.js CHANGED
@@ -7,7 +7,7 @@ const _args = process.argv.slice(2);
7
7
  const flags = [];
8
8
  const args = [];
9
9
  const COMMANDS = ["run", "build", "test", "init"];
10
- const version = "0.3.0";
10
+ const version = "0.3.1";
11
11
  for (const arg of _args) {
12
12
  if (arg.startsWith("-"))
13
13
  flags.push(arg);
package/bin/init.js CHANGED
@@ -9,7 +9,7 @@ export async function init(args) {
9
9
  input: process.stdin,
10
10
  output: process.stdout,
11
11
  });
12
- console.log(chalk.bold("as-test init v0.3.0") + "\n");
12
+ console.log(chalk.bold("as-test init v0.3.1") + "\n");
13
13
  console.log(chalk.dim("[1/3]") + " select a target [wasi/bindings]");
14
14
  const target = await ask(chalk.dim(" -> "), rl);
15
15
  if (!TARGETS.includes(target)) {
@@ -172,7 +172,7 @@ const exports = instantiate(module, {});`);
172
172
  if (!pkg["devDependencies"])
173
173
  pkg["devDependencies"] = {};
174
174
  if (!pkg["devDependencies"]["as-test"])
175
- pkg["devDependencies"]["as-test"] = "^0.3.0";
175
+ pkg["devDependencies"]["as-test"] = "^0.3.1";
176
176
  if (target == "bindings") {
177
177
  pkg["type"] = "module";
178
178
  }
package/bin/run.js CHANGED
@@ -22,7 +22,7 @@ export async function run() {
22
22
  console.log(chalk.bold.blueBright(`| _ || __| ___|_ _|| __|| __||_ _|`));
23
23
  console.log(chalk.bold.blueBright(`| ||__ ||___| | | | __||__ | | | `));
24
24
  console.log(chalk.bold.blueBright(`|__|__||_____| |_| |_____||_____| |_| `));
25
- console.log(chalk.dim("\n------------------- v0.3.0 -------------------\n"));
25
+ console.log(chalk.dim("\n------------------- v0.3.1 -------------------\n"));
26
26
  }
27
27
  for (const plugin of Object.keys(config.plugins)) {
28
28
  if (!config.plugins[plugin])
package/cli/index.ts CHANGED
@@ -11,7 +11,7 @@ const args: string[] = [];
11
11
 
12
12
  const COMMANDS: string[] = ["run", "build", "test", "init"];
13
13
 
14
- const version = "0.3.0";
14
+ const version = "0.3.1";
15
15
 
16
16
  for (const arg of _args) {
17
17
  if (arg.startsWith("-")) flags.push(arg);
package/cli/init.ts CHANGED
@@ -9,7 +9,7 @@ export async function init(args: string[]) {
9
9
  input: process.stdin,
10
10
  output: process.stdout,
11
11
  });
12
- console.log(chalk.bold("as-test init v0.3.0") + "\n");
12
+ console.log(chalk.bold("as-test init v0.3.1") + "\n");
13
13
  console.log(chalk.dim("[1/3]") + " select a target [wasi/bindings]");
14
14
  const target = await ask(chalk.dim(" -> "), rl);
15
15
  if (!TARGETS.includes(target)) {
@@ -193,7 +193,7 @@ const exports = instantiate(module, {});`,
193
193
  }
194
194
  if (!pkg["devDependencies"]) pkg["devDependencies"] = {};
195
195
  if (!pkg["devDependencies"]["as-test"])
196
- pkg["devDependencies"]["as-test"] = "^0.3.0";
196
+ pkg["devDependencies"]["as-test"] = "^0.3.1";
197
197
  if (target == "bindings") {
198
198
  pkg["type"] = "module";
199
199
  }
package/cli/run.ts CHANGED
@@ -42,7 +42,7 @@ export async function run() {
42
42
  chalk.bold.blueBright(`|__|__||_____| |_| |_____||_____| |_| `),
43
43
  );
44
44
  console.log(
45
- chalk.dim("\n------------------- v0.3.0 -------------------\n"),
45
+ chalk.dim("\n------------------- v0.3.1 -------------------\n"),
46
46
  );
47
47
  }
48
48
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "as-test",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Testing framework for AssemblyScript. Compatible with WASI or Bindings ",
5
5
  "types": "assembly/index.ts",
6
6
  "author": "Jairus Tanaka",
@@ -31,7 +31,6 @@
31
31
  "as-variant": "^0.4.1",
32
32
  "chalk": "^5.3.0",
33
33
  "glob": "^11.0.0",
34
- "jest": "^29.7.0",
35
34
  "json-as": "^0.9.14",
36
35
  "typer-diff": "^1.1.1"
37
36
  },
package/run/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@as-test/run",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Testing framework for AssemblyScript. Compatible with WASI or Bindings ",
5
5
  "main": "./lib/index.js",
6
6
  "author": "Jairus Tanaka",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@as-test/transform",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Testing framework for AssemblyScript. Compatible with WASI or Bindings ",
5
5
  "main": "./lib/index.js",
6
6
  "author": "Jairus Tanaka",
Binary file
package/jest.test.js DELETED
@@ -1,44 +0,0 @@
1
- describe("Math operations", () => {
2
- // Setup before each test in this group (optional)
3
- beforeEach(() => {
4
- log("Initializing test...");
5
- });
6
-
7
- // Teardown after each test in this group (optional)
8
- afterEach(() => {
9
- log("Cleaning up after test...");
10
- });
11
-
12
- test("Addition", () => {
13
- expect(1 + 2).toBe(3);
14
- });
15
-
16
- test("Comparison", () => {
17
- expect(5).toBeGreaterThan(3);
18
- expect(2).toBeLessThan(4);
19
- });
20
-
21
- test("Type checking", () => {
22
- expect("hello").toBeString();
23
- expect(true).toBeBoolean();
24
- expect(10.5).toBeNumber();
25
- });
26
- });
27
-
28
- let myArray = [];
29
-
30
- describe("Array manipulation", () => {
31
- beforeAll(() => {
32
- myArray = [1, 2, 3];
33
- });
34
-
35
- test("Array length", () => {
36
- expect(myArray).toHaveLength(3);
37
- });
38
-
39
- test("Array inclusion", () => {
40
- expect(myArray).toContain(2);
41
- });
42
- });
43
-
44
- function foo() {}