Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds Digital Twin Runner utility #110

Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .github/workflows/runner.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Digital twin runner

on:
push:
paths:
- 'servers/execution/**'
pull_request:
paths:
- 'servers/execution/**'
workflow_dispatch:
paths:
- 'servers/execution/**'

jobs:
test-runner:
name: Test digital twin runner
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
cache: "yarn"
cache-dependency-path: "**/yarn.lock"

- name: Run linting checks on runner
run: |
cd servers/execution/runner
yarn install
yarn syntax

- name: Build the runner
if: success() || failure()
run: |
cd servers/execution/runner
yarn install
yarn build

- name: Run tests
if: success() || failure()
run: |
cd servers/execution/runner
yarn install
yarn test
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# NPM registry configuration
.yarnrc
.npmrc

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

Expand Down
2 changes: 1 addition & 1 deletion client/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
playwright/.auth/
playwright/.auth/
6 changes: 6 additions & 0 deletions servers/execution/runner/.eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
api/
build/
dist/
node_modules/
script/
src/types.ts
53 changes: 53 additions & 0 deletions servers/execution/runner/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"env": {
"jest": true,
//"jest/globals": true,
"node": true
},
"extends": [
"eslint:recommended",
"airbnb-base",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"settings": {
"import/resolver": {
"node": {
"extensions": [".js"]
}
}
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"requireConfigFile": false,
"ecmaVersion": 2022,
"sourceType": "module" // Allows for the use of imports
},
"plugins": ["jest", "@typescript-eslint", "import"],
"rules": {
"import/no-extraneous-dependencies": ["error", { "devDependencies": true }],
"no-console": "error",
"import/first": "error",
"linebreak-style": 0, // disable linter linebreak rule, to allow for both unix and windows developement
"import/no-unresolved": "off", // Whatever IDE will pass an error if if the module is not found, so no reason for this..
"import/extensions": "off", // That includes the production build.. We use linter for code checking / clean code optimization..
"no-use-before-define": "off"
},
"root": true,

"overrides": [
{
"files": ["*.ts"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"requireConfigFile": false,
"project": ["./tsconfig.json"]
},
"plugins": ["@typescript-eslint"]
}
]
}
7 changes: 7 additions & 0 deletions servers/execution/runner/.npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
src
test
jest.config.json
tsconfig.json
.eslintignore
.eslintrc
.env
4 changes: 4 additions & 0 deletions servers/execution/runner/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"singleQuote": true,
"trailingComma": "all"
}
Loading