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

[4.3] Switching from Codeception to Cypress for tests #38422

Merged
merged 121 commits into from
Aug 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
121 commits
Select commit Hold shift + click to select a range
922b08e
wip
rdeutz May 31, 2022
6555d6c
ignore a local cypress.json file
rdeutz Jun 1, 2022
3944b98
it needs a / ?
rdeutz Jun 1, 2022
942c85d
untrack a local cypress.json file
rdeutz Jun 1, 2022
2c688c7
import npm package
rdeutz Jun 1, 2022
63adb59
remove most of codeception tests
rdeutz Jun 1, 2022
af486d9
Updating to Cypress 10
Hackwar Jun 2, 2022
a3cc100
Adding a few tests
Hackwar Jun 2, 2022
bf80b76
Migrating a bunch of acceptance tests to cypress
Hackwar Jun 4, 2022
bbaae38
Merge pull request #1 from Hackwar/cypress
Hackwar Jun 5, 2022
7b5295d
prepare for drone
rdeutz Jun 5, 2022
c0c2bc0
remove codeception tests
rdeutz Jun 5, 2022
2d417dd
lint fix
rdeutz Jun 5, 2022
7e2c4b9
fix env var names
rdeutz Jun 5, 2022
eea49bc
copy all files
rdeutz Jun 5, 2022
ca226f9
remove other test for testing cypress
rdeutz Jun 6, 2022
02cfd31
no copy
rdeutz Jun 6, 2022
d0f1424
install cypress binary
rdeutz Jun 6, 2022
d29f894
server url
rdeutz Jun 6, 2022
9c5af3a
start apache
rdeutz Jun 6, 2022
97dd40b
Merge pull request #2 from joomla/4.2-dev
Hackwar Jun 6, 2022
9d11b35
switch to env variables
rdeutz Jun 7, 2022
60de4fc
delete configuration before install
rdeutz Jun 7, 2022
25813b6
set using chrome
rdeutz Jun 7, 2022
9e81cda
call cypress direcly
rdeutz Jun 7, 2022
fff5d0b
call script
rdeutz Jun 7, 2022
4f8d3dc
add other browsers
rdeutz Jun 8, 2022
9fa8def
delete migrate to cypress 10
rdeutz Jun 8, 2022
0f552ec
disable video and screenshots
rdeutz Jun 8, 2022
3b8285f
Use firefox disable npm for testing
HLeithner Jun 12, 2022
2023903
next try
HLeithner Jun 12, 2022
24ee296
Updating cypress to 10.1.0
Hackwar Jun 14, 2022
b8b099b
Merge branch '4.2-dev' of https://github.com/joomla/joomla-cms into c…
Hackwar Jun 14, 2022
6f3ec91
test verify
rdeutz Jul 2, 2022
a82e4a2
Update cypress
HLeithner Jul 2, 2022
80a9230
Disable additional tasks after cypress install
HLeithner Jul 2, 2022
6497529
Update cypress config
HLeithner Jul 2, 2022
156e088
Update cypress config
HLeithner Jul 2, 2022
7e4073a
Update cypress config
HLeithner Jul 2, 2022
e0e7f10
Update cypress config
HLeithner Jul 2, 2022
0490d96
Update cypress config
HLeithner Jul 2, 2022
4d7dbf3
Update cypress config
HLeithner Jul 2, 2022
bc755da
Update cypress config
HLeithner Jul 2, 2022
3c45955
Update cypress config
HLeithner Jul 2, 2022
5986744
Update cypress config
HLeithner Jul 2, 2022
f4fc8d0
Update cypress config
HLeithner Jul 2, 2022
fb954a9
cypress
HLeithner Jul 2, 2022
578ca3d
cypress
HLeithner Jul 2, 2022
39ca087
cypress
HLeithner Jul 2, 2022
e534e59
cypress
HLeithner Jul 2, 2022
cf86d53
cypress
HLeithner Jul 2, 2022
d1ecf4c
Increase cypress viewport
HLeithner Jul 2, 2022
dd0b778
Merge branch '4.2-dev' of https://github.com/joomla/joomla-cms into c…
Hackwar Jul 27, 2022
bff1737
Updating npm dependencies
Hackwar Jul 27, 2022
a1a211f
Merge branch 'cypress' of https://github.com/joomla-projects/joomla-c…
Hackwar Jul 27, 2022
64044b2
update joomla-cypress to 0.0.5
rdeutz Aug 5, 2022
0c88182
fix webauth table (#38320)
heelc29 Jul 29, 2022
e2f36e2
fix backupcodes list view (#38319)
heelc29 Jul 29, 2022
749663c
Remove filename from mod_quickicon manifest (#38309)
richard67 Jul 29, 2022
113cabd
fix yubico.com link (#38304)
tecpromotion Jul 29, 2022
8e1fbc5
Fix Deprecated warning on login (#38300)
joomdonation Jul 29, 2022
ca81055
deprecated php 8.1 (#38292)
alikon Jul 29, 2022
2a43843
[4.2] mod_breadcrumbs. Fix several issues with ld+json structured dat…
GHSVS-de Jul 29, 2022
72eff35
Fix error (stdClass|array) to string conversion in article version hi…
sonvnn Jul 29, 2022
75b090c
Do not show the webauthn form on the registration page (#38341)
roland-d Jul 31, 2022
57ea09b
'notice' to 'warning' in backup notification (#38278)
Kostelano Aug 1, 2022
1c58f02
[4.2] com_media (Mediamanager) configuration view. Text fields to tex…
GHSVS-de Aug 1, 2022
b588ff4
Fix redirect on login url error (#38299)
joomdonation Aug 1, 2022
771f234
column select rtl css (#38360)
brianteeman Aug 1, 2022
1848be9
Configure Renovate (#38344)
joomla-dependency-bot Aug 3, 2022
793e800
working link to license (#38366)
brianteeman Aug 3, 2022
40dd286
wip
rdeutz Aug 8, 2022
b4bd7b1
remove most of codeception tests
rdeutz Aug 8, 2022
7ba9a17
Migrating a bunch of acceptance tests to cypress
rdeutz Aug 8, 2022
1bdf036
Update cypress
rdeutz Aug 8, 2022
31b751c
Merge branch '4.3-dev' of https://github.com/joomla/joomla-cms into c…
Hackwar Aug 8, 2022
feb5941
Commenting videos from gitignore
Hackwar Aug 8, 2022
6104136
Commenting more stuff in gitignore
Hackwar Aug 8, 2022
5ef8584
Updating Drone to use cypress
Hackwar Aug 8, 2022
38d8bf6
Merge branch 'cypress' of https://github.com/joomla-projects/joomla-c…
Hackwar Aug 8, 2022
2f3670a
Updating dependencies
Hackwar Aug 8, 2022
d7abc1d
Fixing drone.yml
Hackwar Aug 8, 2022
3e4cfec
Uncommenting gitignore
Hackwar Aug 8, 2022
dc99964
Removing wrong files
Hackwar Aug 8, 2022
7194c69
Switch drone over to cypress images
Hackwar Aug 8, 2022
792e145
Fixing merge error
Hackwar Aug 8, 2022
b51e340
Removing old config file
Hackwar Aug 8, 2022
bdbd61c
Fixing npm scripts for cypress
Hackwar Aug 8, 2022
c09c3a0
Merge branch '4.3-dev' of https://github.com/joomla/joomla-cms into c…
Hackwar Aug 9, 2022
30c7092
Updating joomla-cypress to 0.0.7
Hackwar Aug 9, 2022
3bb0612
Delete .local.cypress.config.js
Hackwar Aug 10, 2022
4908319
Merge branch '4.3-dev' into cypress
Hackwar Aug 15, 2022
1076806
Updating joomla-cypress to 0.0.8
Hackwar Aug 15, 2022
9046b73
Enabling screenshots and videos for cypress
Hackwar Aug 15, 2022
3a322a9
Adding npm cache
Hackwar Aug 15, 2022
4bbfe72
Fixing cypress run script
Hackwar Aug 15, 2022
7008812
Updating cypress to 10.6.0
Hackwar Aug 18, 2022
ae6d0dc
Remove old install.spec.js
Hackwar Aug 18, 2022
f72af31
Enable preparations for tests after installation
Hackwar Aug 18, 2022
33bf142
Add waits for page reloads
Hackwar Aug 18, 2022
7f2f198
Updating joomla-cypress
Hackwar Aug 18, 2022
5a53086
Adding UserList tests
Hackwar Aug 18, 2022
25b2d47
Optimizations for docker run
Hackwar Aug 18, 2022
72d9bbe
Fixing paths
Hackwar Aug 18, 2022
f4f0d48
Config tests
Hackwar Aug 18, 2022
7f178ab
Fixing paths
Hackwar Aug 18, 2022
94c10c9
Further config changes
Hackwar Aug 18, 2022
2c5af06
One more test
Hackwar Aug 18, 2022
b55f684
Changing prefix
Hackwar Aug 19, 2022
9aa9dbe
Fixing some more tests
Hackwar Aug 19, 2022
1a3cdd4
Removing old fixture file
Hackwar Aug 21, 2022
2491eb0
Moving environment vars around
Hackwar Aug 21, 2022
83e2b3b
Adding excluded files
Hackwar Aug 21, 2022
d1dd902
Shortening test group names to have shorter db prefixes
Hackwar Aug 21, 2022
ccfe206
Adding db_type
Hackwar Aug 21, 2022
323a5e5
Several fixes
Hackwar Aug 21, 2022
2662a47
Updating to joomla-cypress 0.0.10
Hackwar Aug 21, 2022
d5b8116
Fixing several issues
Hackwar Aug 21, 2022
34df959
Updating joomla-cypress to 0.0.11
Hackwar Aug 21, 2022
7e68c1d
Updating joomla-cypress to 0.0.12
Hackwar Aug 21, 2022
a2228fd
Merge branch '4.3-dev' into cypress
rdeutz Aug 24, 2022
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
46 changes: 27 additions & 19 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ steps:
- name: npm
image: node:16-alpine
depends_on: [ phpcs ]
volumes:
- name: npm-cache
path: /tmp/npm-cache
environment:
npm_config_cache: /tmp/npm-cache
commands:
- npm ci --unsafe-perm

Expand Down Expand Up @@ -227,21 +232,21 @@ steps:
depends_on:
- phpmax-api-mysql
- phpmax-api-postgres
image: joomlaprojects/docker-images:systemtests
image: joomlaprojects/docker-images:cypress
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" mysql
- bash tests/cypress/drone-system-run.sh "$(pwd)" cmysql mysqli mysql

- name: phpmax-system-mysql
depends_on:
- phpmax-api-mysql
- phpmax-api-postgres
image: joomlaprojects/docker-images:systemtests8.1
image: joomlaprojects/docker-images:cypress8.1
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" mysqlphpmax
- bash tests/cypress/drone-system-run.sh "$(pwd)" cmysqlmax mysqli mysql

# - name: phpnext-system-mysql
# depends_on:
Expand All @@ -257,21 +262,21 @@ steps:
depends_on:
- phpmax-api-mysql
- phpmax-api-postgres
image: joomlaprojects/docker-images:systemtests
image: joomlaprojects/docker-images:cypress
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" postgres
- bash tests/cypress/drone-system-run.sh "$(pwd)" cpostgres pgsql postgres

- name: phpmax-system-postgres
depends_on:
- phpmax-api-mysql
- phpmax-api-postgres
image: joomlaprojects/docker-images:systemtests8.1
image: joomlaprojects/docker-images:cypress8.1
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" postgresphpmax
- bash tests/cypress/drone-system-run.sh "$(pwd)" cpostgresmax pgsql postgres

# - name: phpnext-system-postgres
# depends_on:
Expand All @@ -287,21 +292,21 @@ steps:
depends_on:
- phpmax-system-mysql
- phpmax-system-postgres
image: joomlaprojects/docker-images:systemtests
image: joomlaprojects/docker-images:cypress
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" mysql8
- bash tests/cypress/drone-system-run.sh "$(pwd)" cmysql8 mysqli mysql8

- name: phpmax-system-mysql8
depends_on:
- phpmax-system-mysql
- phpmax-system-postgres
image: joomlaprojects/docker-images:systemtests8.1
image: joomlaprojects/docker-images:cypress8.1
environment:
JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK: 1
commands:
- bash tests/Codeception/drone-system-run.sh "$(pwd)" mysql8phpmax
- bash tests/cypress/drone-system-run.sh "$(pwd)" cmysql8max mysqli mysql8

# - name: phpnext-system-mysql8
# depends_on:
Expand All @@ -316,17 +321,17 @@ steps:
- name: artifacts-system-tests
image: cschlosser/drone-ftps
depends_on:
# - phpnext-system-mysql
# - phpnext-system-mysql8
# - phpnext-system-postgres
# - phpnext-system-mysql
# - phpnext-system-mysql8
# - phpnext-system-postgres
- phpmax-system-mysql
- phpmax-system-mysql8
- phpmax-system-postgres
- phpmin-system-mysql
- phpmin-system-mysql8
- phpmin-system-postgres
# - phpnext-api-mysql
# - phpnext-api-postgres
# - phpnext-api-mysql
# - phpnext-api-postgres
- phpmax-api-mysql
- phpmax-api-postgres
- phpmin-api-mysql
Expand All @@ -337,7 +342,7 @@ steps:
FTP_PASSWORD:
from_secret: ftppassword
PLUGIN_HOSTNAME: ci.joomla.org:21
PLUGIN_SRC_DIR: /tests/Codeception/_output/
PLUGIN_SRC_DIR: /tests/cypress/output/
PLUGIN_DEST_DIR: /artifacts
PLUGIN_SECURE: false
PLUGIN_EXCLUDE: ^\.git/$
Expand All @@ -353,6 +358,9 @@ volumes:
- name: composer-cache
host:
path: /tmp/composer-cache
- name: npm-cache
host:
path: /tmp/npm-cache

services:
- name: mysql
Expand Down Expand Up @@ -475,6 +483,6 @@ trigger:

---
kind: signature
hmac: e1fe0d199dce2362ee1b27adeeafc64fa2a955fcd66db2d90a266612fb96b0c1
hmac: 916fe89f8d920e8471b32aae02bfe192abf24cd035b5f1ea73452662c1c92895

...
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,9 @@ RoboFile.ini
# Media Manager
/media/com_media/js/mediamanager.min.js.map
/media/com_media/css/mediamanager.min.css.map

#cypress
/tests/cypress/screenshots
!/tests/cypress/screenshots/.gitkeep
/tests/cypress/videos
!/tests/cypress/videos/.gitkeep
32 changes: 32 additions & 0 deletions cypress.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
const { defineConfig } = require('cypress')

module.exports = defineConfig({
fixturesFolder: 'tests/cypress/fixtures',
videosFolder: 'tests/cypress/output/videos',
screenshotsFolder: 'tests/cypress/output/screenshots',
viewportHeight: 1000,
viewportWidth: 1200,
e2e: {
setupNodeEvents(on, config) {},
baseUrl: 'http://localhost/',
specPattern: 'tests/cypress/integration/**/*.cy.{js,jsx,ts,tsx}',
supportFile: 'tests/cypress/support/index.js',
scrollBehavior: 'center',
browser: 'firefox',
screenshotOnRunFailure: true,
video: false
},
env: {
sitename: 'Joomla CMS Test',
name: 'jane doe',
email: '[email protected]',
username: 'ci-admin',
password: 'joomla-17082005',
db_type: 'MySQLi',
db_host: 'localhost',
db_name: 'test_joomla',
db_user: 'root',
db_password: '',
db_prefix: 'jos_',
},
})
Loading