test: Run pnpm test
in CI on all PRs and pushes to main (#7)
All checks were successful
/ test (push) Successful in 10s
All checks were successful
/ test (push) Successful in 10s
Resolves #6. Reviewed-on: #7 Co-authored-by: Glen Whitney <glen@studioinfinity.org> Co-committed-by: Glen Whitney <glen@studioinfinity.org>
This commit is contained in:
parent
036def4a0c
commit
64f99c0f2d
2 changed files with 25 additions and 0 deletions
14
.forgejo/workflows/continuous-integration.yaml
Normal file
14
.forgejo/workflows/continuous-integration.yaml
Normal file
|
@ -0,0 +1,14 @@
|
|||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches: [main]
|
||||
jobs:
|
||||
test:
|
||||
runs-on: docker
|
||||
container:
|
||||
image: node:23
|
||||
steps:
|
||||
- uses: https://code.forgejo.org/actions/checkout@v4
|
||||
- run: npm install -g pnpm@10.8.0
|
||||
- run: pnpm install
|
||||
- run: pnpm test
|
11
src/number/__test__/Number.spec.js
Normal file
11
src/number/__test__/Number.spec.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
import assert from 'assert'
|
||||
import {Number} from '../Number.js'
|
||||
|
||||
describe('Number Type', () => {
|
||||
it('correctly recognizes numbers', () => {
|
||||
assert(Number.test(3))
|
||||
assert(Number.test(NaN))
|
||||
assert(Number.test(Infinity))
|
||||
assert(!Number.test("3"))
|
||||
})
|
||||
})
|
Loading…
Add table
Reference in a new issue