Skip to content

Add Config CLI to the connector #51

Add Config CLI to the connector

Add Config CLI to the connector #51

Workflow file for this run

name: Continuous Integration
on:
pull_request:
branches:
- main
jobs:
unit_tests:
name: Run Node.js unit tests
runs-on: ubuntu-latest
steps:
- name: Checkout (GitHub)
uses: actions/checkout@v3
with:
path: cosmos
- name: Log in to GitHub Container Registry 📦
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Start Azure Cosmos DB emulator
run:
docker run --detach --publish 8081:8081 --publish 10250-10255:10250-10255 mcr.microsoft.com/cosmosdb/linux/azure-cosmos-emulator:latest
- name: Setup database
run: |
sleep 120
echo "$(docker ps)"
cd cosmos/script
npm install --save @azure/cosmos
node app.js
- name: Build connector
run: |
cd cosmos
npm install --save @azure/cosmos
npm run build
- name: Generate the connector configuration
run: |
cd cosmos
chmod +x ./dist/cli/index.js
./dist/cli/index.js update
- name: Start connector
run: |
cd cosmos
export HASURA_CONFIGURATION_DIRECTORY="."
npm run start serve --configuration .
- name: Checkout ndc-spec
uses: actions/checkout@v3
with:
repository: hasura/ndc-spec
path: ndc-spec
- name: Run ndc-test
working-directory: ndc-spec
run: cargo run --bin ndc-test -- replay --endpoint http://0.0.0.0:8080 --snapshots-dir ../cosmos/ndc-test-snapshots