You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2022/04/21 19:27:56 UTC

[GitHub] [couchdb-fauxton] Antonio-Maranhao commented on a diff in pull request #1349: switch from Travis to GH Actions

Antonio-Maranhao commented on code in PR #1349:
URL: https://github.com/apache/couchdb-fauxton/pull/1349#discussion_r855502789


##########
.github/workflows/main.yml:
##########
@@ -0,0 +1,78 @@
+name: CI
+on: [push]
+jobs:
+  run-unit-tests:
+    name: Run unit tests
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/checkout@v2
+    - uses: actions/setup-node@v2
+      with:
+        node-version: '14'
+    - run: ./bin/build-couchdb-dev.sh

Review Comment:
   Isn't this only needed for e2e tests, which it's already being called below?



##########
.github/workflows/main.yml:
##########
@@ -0,0 +1,78 @@
+name: CI
+on: [push]
+jobs:
+  run-unit-tests:
+    name: Run unit tests
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/checkout@v2
+    - uses: actions/setup-node@v2
+      with:
+        node-version: '14'
+    - run: ./bin/build-couchdb-dev.sh
+      # env:
+      #   COUCHDB_IMAGE: "couchdb:dev"
+      #   NIGHTWATCH_SKIPTAGS: "search,nonpartitioned"
+    - name: Install npm packages
+      run: |
+        npm install -g npm@latest
+        npm ci
+        npm ls --production --depth=0
+    - name: Run style check
+      run: npm run stylecheck
+    - name: Run unit tests
+      run: npm run test
+  run-e2e-tests:
+    name: Run e2e tests
+    runs-on: ubuntu-latest
+    needs: [run-unit-tests]
+    strategy:
+      matrix:
+        include:
+          - COUCHDB_IMAGE: apache/couchdb:3
+            NIGHTWATCH_SKIPTAGS: "search,nonpartitioned,couchdb-v2-only"
+          - COUCHDB_IMAGE: apache/couchdb:2.3.1
+            NIGHTWATCH_SKIPTAGS: "search,partitioned"
+          # - COUCHDB_IMAGE: "couchdb:dev"
+          #   NIGHTWATCH_SKIPTAGS: "search,nonpartitioned"

Review Comment:
   Please remove comments



##########
package.json:
##########
@@ -46,7 +47,7 @@
     "less-loader": "^10.2.0",
     "mini-css-extract-plugin": "^2.6.0",
     "mock-local-storage": "^1.1.20",
-    "nightwatch": "^1.7.13",
+    "nightwatch": "^2.0.10",

Review Comment:
   Can you please update nightwatch to 2.1.3 because it includes a vulnerability fix and some bug fixes.



##########
package.json:
##########
@@ -1,6 +1,6 @@
 {
   "name": "fauxton",
-  "version": "1.2.9",
+  "version": "1.3.0",

Review Comment:
   Please change back to 1.2.9 because traditionally we only bump this version when there's a new CouchDB release.



##########
package-lock.json:
##########
@@ -1,6 +1,6 @@
 {
   "name": "fauxton",
-  "version": "1.2.9",
+  "version": "1.3.0",

Review Comment:
   Same here, revert back to 1.2.9



##########
.github/workflows/main.yml:
##########
@@ -0,0 +1,78 @@
+name: CI
+on: [push]
+jobs:
+  run-unit-tests:
+    name: Run unit tests
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/checkout@v2
+    - uses: actions/setup-node@v2
+      with:
+        node-version: '14'
+    - run: ./bin/build-couchdb-dev.sh
+      # env:
+      #   COUCHDB_IMAGE: "couchdb:dev"
+      #   NIGHTWATCH_SKIPTAGS: "search,nonpartitioned"

Review Comment:
   Please remove comments



##########
tests.md:
##########
@@ -20,40 +20,41 @@ E.g.: to run tests under the `addons/cors` path:
 
 ## End-to-end tests
 
-To run selenium locally you need Docker installed. Selenium runs in a Docker container and connects to a CouchDB instance in another container. To start them run the command:
-
-    npm run docker:up
-
-You can run `npm run docker:logs` to see when the CouchDB instance is ready to go. You also need a Fauxton server instance runnning:
-
-    grunt debugDev && DIST=./dist/debug ./bin/fauxton
-
-Finally to run the tests:
-
-    grunt nightwatch
+Selenium runs locally in Chrome, and requires a CouchDB instance. To run Selenium tests locally, following the proceeding steps.

Review Comment:
   ```suggestion
   Nightwatch tests require that you have Chrome installed. If you prefer to use another browser, update `test/nightwatch_tests/nightwatch.json.underscore` and install the appropriate driver - see Nightwatch documentation for more details.
   
   The tests also require a CouchDB server but one is started for you using Docker:
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@couchdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org