@reflex-stack/tsp-bun-example 0.1.4 → 0.1.5
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/package.json +1 -1
- package/tests/test.ts +0 -27
package/package.json
CHANGED
package/tests/test.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
// If you have no tests, uncomment this
|
|
2
|
-
// console.log("No test implemented.")
|
|
3
|
-
// process.exit(0)
|
|
4
|
-
|
|
5
|
-
// Import your code directly from src directory thanks to bun
|
|
6
|
-
import { randomFunction } from "../src/index.js"
|
|
7
|
-
import { subRandomFunction } from "../src/submodule/index.js"
|
|
8
|
-
// Import Bun testing lib
|
|
9
|
-
import { describe, test, expect } from "bun:test"
|
|
10
|
-
|
|
11
|
-
describe("Main module", () => {
|
|
12
|
-
test("Should call random", () => {
|
|
13
|
-
const rootResult = randomFunction()
|
|
14
|
-
expect(rootResult).toBe(5)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
17
|
-
|
|
18
|
-
describe("Sub module", () => {
|
|
19
|
-
test("Should call sub random", () => {
|
|
20
|
-
const subResult = subRandomFunction()
|
|
21
|
-
expect(subResult).toBe(60)
|
|
22
|
-
})
|
|
23
|
-
// Test error example
|
|
24
|
-
// test("Should fail", () => {
|
|
25
|
-
// expect(5).toBe(12)
|
|
26
|
-
// })
|
|
27
|
-
})
|