Skip to content

Commit

Permalink
chore(ci): fix canary tests (#12821)
Browse files Browse the repository at this point in the history
Co-authored-by: Ashwin Kumar <[email protected]>
  • Loading branch information
ashwinkumar6 and Ashwin Kumar authored Jan 11, 2024
1 parent 0a5a196 commit 59a4aef
Show file tree
Hide file tree
Showing 2 changed files with 98 additions and 98 deletions.
30 changes: 15 additions & 15 deletions .github/canary-config/canary-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -269,21 +269,21 @@ tests:
sample_name: [delete-user]
spec: delete-user
browser: [chrome, firefox]
- test_name: integ_angular_auth_angular_authenticator
desc: 'Angular Authenticator'
framework: angular
category: auth
sample_name: [amplify-authenticator]
spec: ui-amplify-authenticator
browser: [chrome, firefox]
- test_name: integ_javascript_auth
desc: 'JavaScript Auth CDN'
framework: javascript
category: auth
sample_name: [auth-cdn]
spec: auth-cdn
browser: [chrome, firefox]
amplifyjs_dir: true
# - test_name: integ_angular_auth_angular_authenticator
# desc: 'Angular Authenticator'
# framework: angular
# category: auth
# sample_name: [amplify-authenticator]
# spec: ui-amplify-authenticator
# browser: [chrome, firefox]
# - test_name: integ_javascript_auth
# desc: 'JavaScript Auth CDN'
# framework: javascript
# category: auth
# sample_name: [auth-cdn]
# spec: auth-cdn
# browser: [chrome, firefox]
# amplifyjs_dir: true
- test_name: integ_next_auth_authenticator_and_ssr_page
desc: 'Authenticator and SSR page'
framework: next
Expand Down
166 changes: 83 additions & 83 deletions .github/workflows/callable-canary-sampleapp-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,45 +65,45 @@ jobs:
working-directory: amplify-js-samples-staging
shell: bash

# Angular
- name: Install angular CLI
run: npm install -g @angular/[email protected]
- name: Create angular application
run: npx -p @angular/cli ng new new-angular-app
working-directory: amplify-js-samples-staging/samples/angular/interactions
- name: Remove existing src folder
run: rm -rf src
working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
- name: Copy files from samples staging repo
run: |
rm -r ./samples/angular/interactions/new-angular-app
cp -r ./samples/angular/interactions/chatbot-component ./samples/angular/interactions/new-angular-app
working-directory: amplify-js-samples-staging
- name: Copy test file from samples staging repo
run: |
cp chatbot-component.spec.js new-angular-app.spec.js
working-directory: amplify-js-samples-staging/cypress/integration/interactions
- name: Install dependencies
run: npm install --save --legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
- name: Install amplify
run: |
npm install -g npm@latest
npm install aws-amplify -legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
- name: Start application and run test
run: |
../amplify-js/scripts/retry-yarn-script.sh -s \
"ci:test \
angular \
interactions \
new-angular-app \
new-angular-app \
chrome \
dev" \
-n 3
working-directory: amplify-js-samples-staging
shell: bash
# # Angular
# - name: Install angular CLI
# run: npm install -g @angular/[email protected]
# - name: Create angular application
# run: npx -p @angular/cli ng new new-angular-app
# working-directory: amplify-js-samples-staging/samples/angular/interactions
# - name: Remove existing src folder
# run: rm -rf src
# working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
# - name: Copy files from samples staging repo
# run: |
# rm -r ./samples/angular/interactions/new-angular-app
# cp -r ./samples/angular/interactions/chatbot-component ./samples/angular/interactions/new-angular-app
# working-directory: amplify-js-samples-staging
# - name: Copy test file from samples staging repo
# run: |
# cp chatbot-component.spec.js new-angular-app.spec.js
# working-directory: amplify-js-samples-staging/cypress/integration/interactions
# - name: Install dependencies
# run: npm install --save --legacy-peer-deps
# working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
# - name: Install amplify
# run: |
# npm install -g npm@latest
# npm install aws-amplify -legacy-peer-deps
# working-directory: amplify-js-samples-staging/samples/angular/interactions/new-angular-app
# - name: Start application and run test
# run: |
# ../amplify-js/scripts/retry-yarn-script.sh -s \
# "ci:test \
# angular \
# interactions \
# new-angular-app \
# new-angular-app \
# chrome \
# dev" \
# -n 3
# working-directory: amplify-js-samples-staging
# shell: bash

# Next
- name: Create next application
Expand Down Expand Up @@ -143,75 +143,75 @@ jobs:
working-directory: amplify-js-samples-staging
shell: bash

# Vue
- name: Create Vue application
run: |
npm init vue@3
working-directory: amplify-js-samples-staging/samples/vue/auth
- name: Copy files from samples staging repo
run: |
cp -r ./samples/vue/auth/authenticator-vue3 ./samples/vue/auth/new-vue-app
working-directory: amplify-js-samples-staging
- name: Copy test file from samples staging repo
run: |
cp new-ui-authenticator.spec.js new-vue-app.spec.js
working-directory: amplify-js-samples-staging/cypress/integration/auth
- name: Install amplify
run: |
npm install -g npm@latest
npm install aws-amplify -legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/vue/auth/new-vue-app
- name: Install dependencies
run: npm install --save --legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/vue/auth/new-vue-app
- name: Start application and run test
run: |
../amplify-js/scripts/retry-yarn-script.sh -s \
"ci:test \
vue \
auth \
new-vue-app \
new-vue-app \
chrome \
dev" \
-n 3
working-directory: amplify-js-samples-staging
shell: bash
# Vue
# - name: Create Vue application
# run: |
# npm init vue@3
# working-directory: amplify-js-samples-staging/samples/vue/auth
# - name: Copy files from samples staging repo
# run: |
# cp -r ./samples/vue/auth/authenticator-vue3 ./samples/vue/auth/new-vue-app
# working-directory: amplify-js-samples-staging
# - name: Copy test file from samples staging repo
# run: |
# cp new-ui-authenticator.spec.js new-vue-app.spec.js
# working-directory: amplify-js-samples-staging/cypress/integration/auth
# - name: Install amplify
# run: |
# npm install -g npm@latest
# npm install aws-amplify -legacy-peer-deps
# working-directory: amplify-js-samples-staging/samples/vue/auth/new-vue-app
# - name: Install dependencies
# run: npm install --save --legacy-peer-deps
# working-directory: amplify-js-samples-staging/samples/vue/auth/new-vue-app
# - name: Start application and run test
# run: |
# ../amplify-js/scripts/retry-yarn-script.sh -s \
# "ci:test \
# vue \
# auth \
# new-vue-app \
# new-vue-app \
# chrome \
# dev" \
# -n 3
# working-directory: amplify-js-samples-staging
# shell: bash

# Javascript
# Javascript
- name: Create javascript application
run: |
mkdir -p new-javascript-app/src && cd new-javascript-app
touch index.html src/app.js webpack.config.js
working-directory: amplify-js-samples-staging/samples/javascript/auth
working-directory: amplify-js-samples-staging/samples/javascript/datastore
- name: Install amplify
run: |
npm install -g npm@latest
npm install aws-amplify -legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/javascript/auth/new-javascript-app
working-directory: amplify-js-samples-staging/samples/javascript/datastore/new-javascript-app
- name: Remove existing src folder
run: rm -rf src
working-directory: amplify-js-samples-staging/samples/javascript/auth/new-javascript-app
working-directory: amplify-js-samples-staging/samples/javascript/datastore/new-javascript-app
- name: Copy files from samples staging repo
run: |
rm -r ./samples/javascript/auth/new-javascript-app
cp -r ./samples/javascript/auth/auth-cdn ./samples/javascript/auth/new-javascript-app
rm -r ./samples/javascript/datastore/new-javascript-app
cp -r ./samples/javascript/datastore/basic-crud ./samples/javascript/datastore/new-javascript-app
working-directory: amplify-js-samples-staging
- name: Copy test file from samples staging repo
run: |
cp auth-cdn.spec.js new-javascript-app.spec.js
working-directory: amplify-js-samples-staging/cypress/integration/auth
cp vanilla-js-basic-crud.spec.js new-javascript-app.spec.js
working-directory: amplify-js-samples-staging/cypress/integration/datastore
- name: Install dependencies
run: npm install --save --legacy-peer-deps
working-directory: amplify-js-samples-staging/samples/javascript/auth/new-javascript-app
working-directory: amplify-js-samples-staging/samples/javascript/datastore/new-javascript-app
- name: Start application and run test
env:
AMPLIFY_DIR: ${{ env.AMPLIFY_DIR }}
run: |
../amplify-js/scripts/retry-yarn-script.sh -s \
"ci:test \
javascript \
auth \
datastore \
new-javascript-app \
new-javascript-app \
chrome \
Expand Down

0 comments on commit 59a4aef

Please sign in to comment.