Skip to content

Commit

Permalink
ci: Run tests on Node instead of Bun
Browse files Browse the repository at this point in the history
  • Loading branch information
smessie authored and ajuvercr committed Aug 28, 2024
1 parent ada8208 commit 5222b85
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 38 deletions.
29 changes: 15 additions & 14 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
name: Build & Test with Bun
name: Build and tests with Node.js

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3 # Checkout repo
- name: Checkout
uses: actions/checkout@v3

- name: Setup Bun
uses: oven-sh/setup-bun@v1 # Setup bun
with:
bun-version: latest

- run: bun i # Install dependencies
- run: bun test # Run tests
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 21.x
cache: "npm"

- run: npm ci
- run: npm run build
- run: npm run test
19 changes: 0 additions & 19 deletions .github/workflows/test.yml

This file was deleted.

6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Js-runner

[![Bun CI](https://github.com/rdf-connect/js-runner/actions/workflows/build-test.yml/badge.svg)](https://github.com/rdf-connect/js-runner/actions/workflows/build-test.yml) [![npm](https://img.shields.io/npm/v/@rdfc/js-runner.svg?style=popout)](https://npmjs.com/package/@rdfc/js-runner)
[![Build and tests with Node.js](https://github.com/rdf-connect/js-runner/actions/workflows/build-test.yml/badge.svg)](https://github.com/rdf-connect/js-runner/actions/workflows/build-test.yml) [![npm](https://img.shields.io/npm/v/@rdfc/js-runner.svg?style=popout)](https://npmjs.com/package/@rdfc/js-runner)

Typescript/Javascript executor for an [RDF-Connect](https://rdf-connect.github.io/rdfc.github.io/) pipeline. Starting from a declarative RDF file describing the pipeline.

Expand Down Expand Up @@ -34,7 +34,7 @@ You can execute this pipeline with

```bash
tsc
bun bin/js-runner.js input.ttl
npx bin/js-runner.js input.ttl
```

This example input configuration file uses `owl:imports` to specify additional configuration files.
This example input configuration file uses `owl:imports` to specify additional configuration files.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
"js-runner": "bin/bundle.mjs"
},
"scripts": {
"build": "tsc && tsc-alias && rollup ./dist/index.js --file ./dist/index.cjs --format cjs && bun build --external debug ./bin/js-runner.js --outfile bin/bundle.mjs --target node && npm run build:recompose",
"build:recompose": "sed -z 's/var __require = (id) => {\\n return import.meta.require(id);\\n};/import Module from \"node:module\";\\nconst __require = Module.createRequire(import.meta.url);/' -i bin/bundle.mjs",
"build": "tsc && tsc-alias",
"watch": "tsc -w",
"test": "vitest run --coverage --coverage.include src",
"prepare": "husky",
Expand Down

0 comments on commit 5222b85

Please sign in to comment.