Merge branch 'master' into gql/editor-updates

This commit is contained in:
Liyas Thomas
2020-03-01 00:29:52 +05:30
committed by GitHub
2 changed files with 11 additions and 26 deletions

View File

@@ -1,4 +1,4 @@
# == INSTRUCTIONS FOR SETTING UP TRAVIS (and GitHub Pages) == # == INSTRUCTIONS FOR SETTING UP TRAVIS ==
# #
# 1. Find this repository in your Travis-CI dashboard. # 1. Find this repository in your Travis-CI dashboard.
# open settings and add an environment variable called # open settings and add an environment variable called
@@ -8,12 +8,10 @@
# **DO NOT TURN ON 'Display value in build log'!!!!** # **DO NOT TURN ON 'Display value in build log'!!!!**
# #
# 2. Push the code to the repository. # 2. Push the code to the repository.
# 3. Set the GitHub Pages source in the GitHub repository settings to the
# gh-pages branch.
language: node_js language: node_js
node_js: node_js:
- "12" - lts/*
os: linux os: linux
@@ -22,35 +20,20 @@ addons:
packages: packages:
- libgconf-2-4 # cypress binary dependency - libgconf-2-4 # cypress binary dependency
env: cache: npm
- DEPLOY_ENV=POSTWOMAN_IO
cache:
npm: true
directories:
- "node_modules"
- ~/.cache
branches: branches:
only: only:
- "master" - master
install: install:
- "npm install firebase-tools" - npm ci
- "npm install"
before_script: before_script:
- "npm run build" # use nuxt build and start to run tests - npm run build # use nuxt build and start to run tests
- "npm run test"
script: script:
- "cd functions" - npm test
- "npm install"
- "cd .."
- "npm run generate"
notifications: notifications:
webhooks: https://www.travisbuddy.com webhooks: https://www.travisbuddy.com
after_success:
- firebase deploy --token $FIREBASE_TOKEN

View File

@@ -4,6 +4,7 @@ describe("Proxy disabled - local request", () => {
.get("#url") .get("#url")
.then(el => expect(el.val() === "https://api.thecatapi.com").to.equal(true)) .then(el => expect(el.val() === "https://api.thecatapi.com").to.equal(true))
.get("#response-details-wrapper") .get("#response-details-wrapper")
.should("be.visible")
.should($wrapper => { .should($wrapper => {
expect($wrapper).to.contain("FAKE Cat API") expect($wrapper).to.contain("FAKE Cat API")
}) })
@@ -15,9 +16,10 @@ describe("Proxy enabled - external request", () => {
cy.enableProxy("/?url=https://api.thecatapi.com&path=") cy.enableProxy("/?url=https://api.thecatapi.com&path=")
.get("#send") .get("#send")
.click() .click()
.get("#response-details-wrapper") .get("#response-details-wrapper", { timeout: 24000 })
.should("be.visible")
.should($wrapper => { .should($wrapper => {
expect($wrapper).to.contain("Cat API") expect($wrapper).to.contain("The Cat API")
}) })
}) })
}) })