Browse Source

refactor: move docker-compose-cypress.yml to cypress directory

pull/4237/head
Wing-Kam Wong 2 years ago
parent
commit
b9a4018764
  1. 22
      .github/workflows/ci-cd.yml
  2. 6
      packages/noco-docs/content/en/engineering/testing.md
  3. 0
      scripts/cypress/docker-compose-cypress.yml
  4. 2
      scripts/markdown/readme/languages/chinese.md
  5. 2
      scripts/markdown/readme/languages/german.md

22
.github/workflows/ci-cd.yml

@ -59,7 +59,7 @@ jobs:
start: |
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/restTableOps.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -105,7 +105,7 @@ jobs:
start: |
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/restViews.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -151,7 +151,7 @@ jobs:
start: |
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/restRoles.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -197,7 +197,7 @@ jobs:
start: |
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/restMisc.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -243,7 +243,7 @@ jobs:
start: |
npm run start:xcdb-api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/xcdb-restTableOps.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -289,7 +289,7 @@ jobs:
start: |
npm run start:xcdb-api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/xcdb-restViews.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -335,7 +335,7 @@ jobs:
start: |
npm run start:xcdb-api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/xcdb-restRoles.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -381,7 +381,7 @@ jobs:
start: |
npm run start:xcdb-api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/xcdb-restMisc.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -612,7 +612,7 @@ jobs:
cp ./scripts/cypress/fixtures/quickTest/noco_0_91_7.db ./packages/nocodb/noco.db
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/quickTest.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200
@ -707,7 +707,7 @@ jobs:
run: npm install
- name: setup mysql
working-directory: ./
run: docker-compose -f ./scripts/docker-compose-cypress.yml up -d
run: docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
- name: run unit tests
working-directory: ./packages/nocodb
run: npm run test:unit
@ -745,7 +745,7 @@ jobs:
start: |
npm run start:api:cache
npm run start:web
docker-compose -f ./scripts/docker-compose-cypress.yml up -d
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up -d
spec: "./scripts/cypress/integration/test/db-independent.js"
wait-on: "http://localhost:8080, http://localhost:3000/_nuxt/assets/img/icons/512x512-trans.png"
wait-on-timeout: 1200

6
packages/noco-docs/content/en/engineering/testing.md

@ -210,7 +210,7 @@ First 3 suites, each have 4 test category
# install dependencies(cypress)
npm install
# start MySQL database using docker compose
docker-compose -f ./scripts/docker-compose-cypress.yml up
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up
# Run backend api using following command
npm run start:xcdb-api:cache
@ -234,7 +234,7 @@ npm run cypress:open
# install dependencies(cypress)
npm install
# start MySQL database using docker compose
docker-compose -f ./scripts/docker-compose-cypress.yml up
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up
# Run backend api using following command
npm run start:api:cache
@ -282,7 +282,7 @@ npm run cypress:open
# install dependencies(cypress)
npm install
# start MySQL database using docker compose
docker-compose -f ./scripts/docker-compose-cypress.yml up
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up
# copy existing xcdb (v0.91.7) database to ./packages/nocodb/
cp ./scripts/cypress/fixtures/quickTest/noco_0_91_7.db ./packages/nocodb/noco.db

0
scripts/docker-compose-cypress.yml → scripts/cypress/docker-compose-cypress.yml

2
scripts/markdown/readme/languages/chinese.md

@ -262,7 +262,7 @@ npm run dev
npm install
# 使用 docker compose 运行带有所需数据库的 mysql 数据库
docker-compose -f ./scripts/docker-compose-cypress.yml up
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up
# 使用以下命令运行后端 api
npm run start:api

2
scripts/markdown/readme/languages/german.md

@ -244,7 +244,7 @@ npm run dev
npm install
# MySQL-Datenbank mit der benötigten Datenbank mit Docker Compose ausführen
docker-compose -f ./scripts/docker-compose-cypress.yml up
docker-compose -f ./scripts/cypress/docker-compose-cypress.yml up
# Backend API mit folgendem Befehl ausführen
npm run start:api

Loading…
Cancel
Save