Skip to content

Commit

Permalink
Merge branch 'maintenance-3.0.x' into ftest_node18
Browse files Browse the repository at this point in the history
  • Loading branch information
poonamyadav252 authored Sep 20, 2023
2 parents b7e2390 + 657147b commit 105051f
Show file tree
Hide file tree
Showing 8 changed files with 59 additions and 73 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/a11y.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ env:

jobs:
a11y:
runs-on: ubuntu-latest
runs-on: [self-hosted, master]
steps:
- uses: actions/checkout@v2
with:
Expand All @@ -48,6 +48,11 @@ jobs:
distribution: 'zulu'
java-version: '11'

- name: Install google chrome
run: |
wget https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_114.0.5735.90-1_amd64.deb
apt install -y --allow-downgrades ./google-chrome-stable_114.0.5735.90-1_amd64.deb
- name: 'Update settings.xml with server configuration'
run: |
echo '<settings>
Expand All @@ -63,9 +68,5 @@ jobs:
- name: Web UI build
run: mvn -B -ntp install

#==================================================================================================================
# this line of code has been commented on due to some driver issues, we will resume it once WEBUI-1266 is resolved.
#==================================================================================================================
# - name: A11y checks
# run: mvn -B -ntp -f plugin/a11y install
#==================================================================================================================
- name: A11y checks
run: mvn -B -ntp -f plugin/a11y install
58 changes: 25 additions & 33 deletions .github/workflows/cross-repo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -168,39 +168,31 @@ jobs:
</servers>
</settings>' > ~/.m2/settings.xml
#==================================================================================================================
# this line of code has been commented on due to some driver issues, we will resume it once WEBUI-1267 is resolved.
#==================================================================================================================
# - name: Nuxeo package build and Ftests
# env:
# RUN_ALL: ${{ github.event.inputs.run_all }}
# BAIL: ${{ github.event.inputs.bail }}
# run: |
# profiles=()
# if [ ${{ github.event.inputs.skip_ftests }} = "false" ]
# then
# profiles+=('ftest')
# fi
# if ${{ github.event.inputs.generate_metrics }}
# then
# profiles+=('metrics')
# fi
# active_profiles=""
# if [ ${#profiles[@]} -gt 0 ]
# then
# active_profiles="-P$(printf -v active_profiles '%s,' "${profiles[@]}" && echo "${active_profiles%,}")"
# fi
# mvn install -ntp $active_profiles -DskipInstall
#==================================================================================================================

#==================================================================================================================
# this line of code has been commented on due to some driver issues, we will resume it once WEBUI-1266 is resolved.
#==================================================================================================================
# - name: A11y checks
# if: ${{ github.event.inputs.skip_a11y == 'false' }}
# run: |
# mvn -B -nsu -f plugin/a11y -ntp install
#==================================================================================================================
- name: Nuxeo package build and Ftests
env:
RUN_ALL: ${{ github.event.inputs.run_all }}
BAIL: ${{ github.event.inputs.bail }}
run: |
profiles=()
if [ ${{ github.event.inputs.skip_ftests }} = "false" ]
then
profiles+=('ftest')
fi
if ${{ github.event.inputs.generate_metrics }}
then
profiles+=('metrics')
fi
active_profiles=""
if [ ${#profiles[@]} -gt 0 ]
then
active_profiles="-P$(printf -v active_profiles '%s,' "${profiles[@]}" && echo "${active_profiles%,}")"
fi
mvn install -ntp $active_profiles -DskipInstall
- name: A11y checks
if: ${{ github.event.inputs.skip_a11y == 'false' }}
run: |
mvn -B -nsu -f plugin/a11y -ntp install
- name: Archive cucumber reports
if: ${{ always() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ftest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
with:
distribution: 'zulu'
java-version: '11'

- name: Determine nuxeo-elements branch to link
id: pick_nuxeo_elements_branch
run: |
Expand Down
44 changes: 18 additions & 26 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,34 +22,26 @@ jobs:
with:
branch: maintenance-3.0.x

#==================================================================================================================
# this line of code has been commented on due to some driver issues, we will resume it once WEBUI-1266 is resolved.
#==================================================================================================================
# a11y:
# uses: nuxeo/nuxeo-web-ui/.github/workflows/[email protected]
# secrets:
# NPM_PACKAGES_TOKEN: ${{ secrets.NPM_PACKAGES_TOKEN }}
# PACKAGES_AUTH_USER: ${{ secrets.PACKAGES_AUTH_USER }}
# PACKAGES_AUTH_TOKEN: ${{ secrets.PACKAGES_AUTH_TOKEN }}
# with:
# branch: maintenance-3.1.x
#==================================================================================================================

#==================================================================================================================
# this line of code has been commented on due to some driver issues, we will resume it once WEBUI-1267 is resolved.
#==================================================================================================================
# ftest:
# uses: nuxeo/nuxeo-web-ui/.github/workflows/[email protected]
# secrets:
# NPM_PACKAGES_TOKEN: ${{ secrets.NPM_PACKAGES_TOKEN }}
# PACKAGES_AUTH_USER: ${{ secrets.PACKAGES_AUTH_USER }}
# PACKAGES_AUTH_TOKEN: ${{ secrets.PACKAGES_AUTH_TOKEN }}
# with:
# branch: maintenance-3.0.x
#==================================================================================================================
a11y:
uses: nuxeo/nuxeo-web-ui/.github/workflows/[email protected]
secrets:
NPM_PACKAGES_TOKEN: ${{ secrets.NPM_PACKAGES_TOKEN }}
PACKAGES_AUTH_USER: ${{ secrets.PACKAGES_AUTH_USER }}
PACKAGES_AUTH_TOKEN: ${{ secrets.PACKAGES_AUTH_TOKEN }}
with:
branch: maintenance-3.0.x

ftest:
uses: nuxeo/nuxeo-web-ui/.github/workflows/[email protected]
secrets:
NPM_PACKAGES_TOKEN: ${{ secrets.NPM_PACKAGES_TOKEN }}
PACKAGES_AUTH_USER: ${{ secrets.PACKAGES_AUTH_USER }}
PACKAGES_AUTH_TOKEN: ${{ secrets.PACKAGES_AUTH_TOKEN }}
with:
branch: maintenance-3.0.x

build:
needs: [ lint, test ]
needs: [ lint, test, a11y, ftest ]
runs-on: [ self-hosted, master ]
steps:
- uses: actions/checkout@v2
Expand Down
4 changes: 3 additions & 1 deletion packages/nuxeo-web-ui-ftest/scripts/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,9 @@ if (process.env.DRIVER_VERSION == null) {
console.log(`${version} detected.`);
const match = version && version.match(/([0-9]+)\./);
if (match) {
const checkVersion = match[1];
// const checkVersion = match[1];
// we will revert this once driver issue is resolved.
const checkVersion = 114;
try {
done = fetch(`https://googlechromelabs.github.io/chrome-for-testing/LATEST_RELEASE_${checkVersion}`).then(
(response) => {
Expand Down
4 changes: 3 additions & 1 deletion plugin/a11y/getDriverVersion.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ try {
}
const match = version && version.match(/([0-9]+)\./);
if (match) {
const checkVersion = match[1];
// const checkVersion = match[1];
// we will revert this once driver issue is resolved.
const checkVersion = 114;
try {
fetch(`https://googlechromelabs.github.io/chrome-for-testing/LATEST_RELEASE_${checkVersion}`).then((response) => {
if (response.ok) {
Expand Down
2 changes: 0 additions & 2 deletions plugin/a11y/test/specs/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ const EXPECTED_VIOLATIONS = {
'aria-command-name': 1,
'aria-roles': 3,
'aria-tooltip-name': 1,
'duplicate-id': 28,
'landmark-one-main': 1,
'meta-viewport': 1,
'page-has-heading-one': 1,
Expand All @@ -17,7 +16,6 @@ const EXPECTED_VIOLATIONS = {
};

const EXPECTED_INCOMPLETE_VIOLATIONS = {
'aria-allowed-attr': 1,
'aria-allowed-role': 7,
'aria-valid-attr-value': 1,
'color-contrast-enhanced': 2,
Expand Down
3 changes: 1 addition & 2 deletions plugin/a11y/test/specs/home.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ const EXPECTED_VIOLATIONS = {
'aria-command-name': 1,
'aria-allowed-attr': 4,
'aria-tooltip-name': 1,
'duplicate-id': 28,
'landmark-one-main': 1,
'meta-viewport': 1,
'page-has-heading-one': 1,
Expand All @@ -18,7 +17,7 @@ const EXPECTED_VIOLATIONS = {

const EXPECTED_INCOMPLETE_VIOLATIONS = {
'aria-allowed-role': 5,
'color-contrast': 8,
'color-contrast-enhanced': 2,
};

describe('Nuxeo Home', () => {
Expand Down

0 comments on commit 105051f

Please sign in to comment.