-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
26 changed files
with
520 additions
and
157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,15 @@ | ||
name: Code analysis checks | ||
on: [push] | ||
jobs: | ||
build: | ||
codeanalysis: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [16.x] | ||
python-version: [3.9] | ||
env: | ||
NAMESPACE: '@plone-collective' | ||
GIT_NAME: volto-authomatic | ||
GIT_USER: 'collective' | ||
GIT_BRANCH: ${GITHUB_REF##*/} | ||
node-version: [20.x] | ||
|
||
steps: | ||
- name: Main checkout | ||
uses: actions/checkout@v2 | ||
|
||
# node setup | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'yarn' | ||
|
||
# node install | ||
- name: Install dependencies | ||
run: yarn install | ||
|
||
- name: Install yo and @plone/generator-volto | ||
run: npm i -g yo @plone/generator-volto | ||
|
||
- name: Setup addon testing environment | ||
run: npx -p @plone/scripts addon clone https://github.com/${{env.GIT_USER}}/${{env.GIT_NAME}}.git --branch ${{env.GIT_BRANCH}} | ||
|
||
# ESlint | ||
- name: ESlint | ||
run: cd addon-testing-project && yarn && yarn lint | ||
|
||
# Stylelint | ||
- name: Stylelint | ||
run: cd addon-testing-project && yarn && yarn stylelint | ||
uses: actions/checkout@v3 | ||
|
||
# Prettier | ||
- name: Prettier | ||
run: cd addon-testing-project && yarn && yarn prettier:ci | ||
- name: Linting | ||
run: make lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,15 @@ | ||
name: Unit tests | ||
name: Unit Tests | ||
on: [push] | ||
jobs: | ||
build: | ||
unit: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [16.x] | ||
python-version: [3.9] | ||
env: | ||
NAMESPACE: '@plone-collective' | ||
GIT_NAME: volto-authomatic | ||
GIT_USER: 'collective' | ||
GIT_BRANCH: ${GITHUB_REF##*/} | ||
node-version: [20.x] | ||
|
||
steps: | ||
- name: Main checkout | ||
uses: actions/checkout@v2 | ||
|
||
# node setup | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'yarn' | ||
|
||
# node install | ||
- name: Install dependencies | ||
run: yarn install | ||
|
||
- name: Install yo and @plone/generator-volto | ||
run: npm i -g yo @plone/generator-volto | ||
|
||
- name: Setup addon testing environment | ||
run: npx -p @plone/scripts addon clone https://github.com/${{env.GIT_USER}}/${{env.GIT_NAME}}.git --branch ${{env.GIT_BRANCH}} | ||
uses: actions/checkout@v3 | ||
|
||
# Unit tests | ||
- name: Unit tests | ||
run: cd addon-testing-project && yarn && CI=true yarn test | ||
run: make test-ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
version: "3" | ||
|
||
services: | ||
|
||
addon-acceptance: | ||
build: | ||
context: ../ | ||
dockerfile: ./dockerfiles/Dockerfile | ||
args: | ||
ADDON_NAME: "${ADDON_NAME}" | ||
ADDON_PATH: "${ADDON_PATH}" | ||
VOLTO_VERSION: ${VOLTO_VERSION:-17} | ||
environment: | ||
RAZZLE_INTERNAL_API_PATH: http://backend-acceptance:55001/plone | ||
RAZZLE_API_PATH: http://localhost:55001/plone | ||
ports: | ||
- 3000:3000 | ||
depends_on: | ||
- backend-acceptance | ||
profiles: | ||
- prod | ||
|
||
backend-acceptance: | ||
image: plone/server-acceptance:${PLONE_VERSION:-6} | ||
ports: | ||
- 55001:55001 | ||
profiles: | ||
- dev | ||
- prod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
const { defineConfig } = require('cypress'); | ||
|
||
module.exports = defineConfig({ | ||
viewportWidth: 1280, | ||
e2e: { | ||
baseUrl: 'http://localhost:3000', | ||
specPattern: 'cypress/tests/*.cy.{js,jsx}', | ||
}, | ||
}); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"name": "Using fixtures to represent data", | ||
"email": "hello@cypress.io", | ||
"body": "Fixtures are a great way to mock data for responses to routes" | ||
} |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// *********************************************************** | ||
// This example plugins/index.js can be used to load plugins | ||
// | ||
// You can change the location of this file or turn off loading | ||
// the plugins file with the 'pluginsFile' configuration option. | ||
// | ||
// You can read more here: | ||
// https://on.cypress.io/plugins-guide | ||
// *********************************************************** | ||
|
||
// This function is called when a project is opened or re-opened (e.g. due to | ||
// the project's config changing) | ||
|
||
module.exports = (on, config) => { | ||
// `on` is used to hook into various events Cypress emits | ||
// `config` is the resolved Cypress config | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import '@plone/volto-testing/cypress/support/commands'; |
Oops, something went wrong.