Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed array spread #248

Closed
wants to merge 55 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
2dd68fa
1541: remove os2display-grid-generator temp, will re-add
sinejespersen May 28, 2024
e88ec3e
1541: change lodash imports and dependency to avoid tree shaking
sinejespersen May 28, 2024
4770389
1541: yarn upgrade
sinejespersen May 28, 2024
ae4b93c
1541: remove unused dependencies
sinejespersen May 28, 2024
1645604
1541: initial work on vite and upgrade node
sinejespersen May 29, 2024
bd83e61
1541: remote component now works
sinejespersen May 29, 2024
aa45f50
1541: readd lodash tree-shaking
sinejespersen May 29, 2024
d14138b
1541: readd os2display-grid-generator
sinejespersen May 29, 2024
230c7fd
1541: readd os2display-grid-generator
sinejespersen May 29, 2024
2a150da
1541: changelog
sinejespersen May 29, 2024
75174ce
1541: correct tiny error, uniqwith instead of uniqWith in import
sinejespersen May 29, 2024
339228e
1541: add eslint to package.json
sinejespersen May 29, 2024
319745d
1541: remove healthcheck
sinejespersen Jun 3, 2024
4743c03
1541: reverse port 3000
sinejespersen Jun 3, 2024
120ddee
1541: move eslint to dev dependencies
sinejespersen Jun 3, 2024
145e99b
1541: update changelog to reflect new repo
sinejespersen Jun 3, 2024
4c91ea8
1541: remove unused path import
sinejespersen Jun 4, 2024
00955c1
Merge pull request #2 from aroskanalen/feature/1541-update-node-migra…
sinejespersen Jun 6, 2024
214dcb3
1541: initial work on vite and upgrade node
sinejespersen May 29, 2024
e21aacd
1541: add eslint to package.json
sinejespersen May 29, 2024
41542d4
1541: initial cypress to playwright
sinejespersen May 31, 2024
02c4810
1541: fix baseurl
sinejespersen May 31, 2024
41c27a9
1541: update readme with playwright
sinejespersen May 31, 2024
5486877
1541: remove cypress specific linting
sinejespersen May 31, 2024
9493161
1541: add yarn.lock without cypress linting
sinejespersen May 31, 2024
1c5c61a
1541: change sdf to localScreenGroup
sinejespersen May 31, 2024
78e2596
1541: campaigntests
sinejespersen May 31, 2024
b527c22
1541: delete campaign cypress tests
sinejespersen May 31, 2024
aff20a4
1541: delete slide cypress tests
sinejespersen May 31, 2024
3445905
1541: delete cypress login tests
sinejespersen May 31, 2024
ffab625
1541: remvoe media tests, and two failing tests
sinejespersen May 31, 2024
bc866b9
1541: theme spec updated
sinejespersen May 31, 2024
b362314
1541: remove tests
sinejespersen May 31, 2024
c924ec6
1541: remove tests
sinejespersen Jun 3, 2024
0a1472f
1541: topbar tests
sinejespersen Jun 3, 2024
a181a10
1541: add theme list tests to theme spec
sinejespersen Jun 3, 2024
c9332e4
1541: delete theme list spec
sinejespersen Jun 3, 2024
2bdb65f
1541: media tests added
sinejespersen Jun 3, 2024
16d3bbb
1541: playlist tests in playwright
sinejespersen Jun 3, 2024
753a009
1541: shared playlist tests added
sinejespersen Jun 3, 2024
f84013c
1541: screen tests
sinejespersen Jun 3, 2024
8e650ab
1541: format screen groups
sinejespersen Jun 3, 2024
479c02f
1541: remove cypress json files
sinejespersen Jun 3, 2024
c921dd7
1541: yarn.lock rebuild
sinejespersen Jun 3, 2024
26bfa31
1541: remove ids used in test
sinejespersen Jun 3, 2024
db56412
1541: update changelog
sinejespersen Jun 3, 2024
a5d4803
1541: add env CI: 'true' to pr.yml to avoid endless tests in GA
sinejespersen Jun 3, 2024
d92e677
1541: delete failing test
sinejespersen Jun 3, 2024
ff08f4f
1541: add reporter: [['html', { open: 'never' }]] to playwright.config
sinejespersen Jun 3, 2024
b63e504
1541: readd remote component
sinejespersen Jun 3, 2024
a5420d0
1541: readd grid generation
sinejespersen Jun 6, 2024
453a0b5
1541: move playwrigt to override, remove version from dockercompose
sinejespersen Jun 6, 2024
9ca3d43
1541: remove ports 3000 (rebase error)
sinejespersen Jun 6, 2024
fe93945
Merge pull request #1 from aroskanalen/feature/1541-cypress-becomes-p…
sinejespersen Jun 6, 2024
3e4568a
173: Removed array spread
tuj Jun 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions vite-env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="vite/client" />
3 changes: 1 addition & 2 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
"airbnb",
"prettier",
"plugin:jsdoc/recommended",
"plugin:prettier/recommended",
"plugin:cypress/recommended"
"plugin:prettier/recommended"
],
"ignorePatterns": ["*.yml"],
"parser": "babel-eslint",
Expand Down
27 changes: 15 additions & 12 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,11 @@ jobs:
docker compose run --rm node yarn install
docker compose run --rm node yarn check-coding-standards

cypress:
name: Cypress
playwright-tests:
name: Playwright
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
browser: ["chrome"]
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -48,16 +46,21 @@ jobs:
- name: Install client
run: docker compose run node yarn

- name: Cypress run
run: docker compose run cypress run --browser ${{ matrix.browser }}
- name: Run playwright
env:
CI: 'true'
run: |
docker compose run --rm node yarn install
docker compose run --rm playwright npx playwright install --with-deps
docker compose run --rm playwright npx playwright test --retries 3


- name: Archive screenshots
if: ${{ failure() }}
uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
if: always()
with:
name: cypress-screenshots-${{ matrix.browser }}
path: cypress/screenshots
retention-days: 7
name: playwright-report
path: playwright-report/
retention-days: 30

changelog:
runs-on: ubuntu-latest
Expand Down
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ yarn-error.log*
# Ignore VS-code
.vscode

# Cypress
cypress/videos/*
cypress/screenshots/*

# Temp files
temp/

Expand All @@ -38,3 +34,7 @@ json-server/
public/config.json
public/access-config.json
public/release.json
/test-results/
/playwright-report/
/blob-report/
/playwright/.cache/
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,21 @@ All notable changes to this project will be documented in this file.

## [Unreleased]

- Removed array spread.

- [#244](https://github.com/aroskanalen/display-admin-client/pull/1)
- Migrate from Cypress to playwright

- [#243](https://github.com/aroskanalen/display-admin-client/pull/2)
- Migrate from CRA to Vite
- Upgrade node from 14 -> 20

- [#242](https://github.com/os2display/display-admin-client/pull/243)
- Add entry in example config for midttrafik api key
- Clean up multi select component a bit, replace reduce with Map logic
- Make the station selector call new api
- Add config to context in app.jsx


## [2.0.2] - 2024-04-25

- [#242](https://github.com/os2display/display-admin-client/pull/242)
Expand Down
14 changes: 10 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,20 @@ docker compose exec node npm --prefix src/redux/api install
docker compose exec node npm --prefix src/redux/api start
```

## Testing with cypress
## Testing with playwright

We use [cypress](https://www.cypress.io/) for testing.
We use [playwright](https://playwright.dev/) for testing.

To run cypress tests in the cypress container:
To run playwright tests with docker:

```shell
docker compose run --rm cypress run
docker compose run --rm playwright npx playwright test
```

To test with user interface, up the containers and change the baseUrl in playwright.config.ts, then:

```shell
yarn playwright test --ui
```

### Linting
Expand Down
9 changes: 0 additions & 9 deletions config-overrides.js

This file was deleted.

6 changes: 0 additions & 6 deletions cypress/fixtures/error.json

This file was deleted.

20 changes: 0 additions & 20 deletions cypress/fixtures/groups/group-successful.json

This file was deleted.

146 changes: 0 additions & 146 deletions cypress/fixtures/groups/groups.json

This file was deleted.

Loading
Loading