Skip to content

Commit

Permalink
Add UI tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nesrineabdmouleh committed Jul 18, 2024
1 parent ad67877 commit b6e71d7
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ui-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
fail-fast: false
matrix: ${{ fromJSON(needs.ui_test_matrix.outputs.matrix) }}
env:
PS_DOCKER: ${{ matrix.PS_VERSION_START }}-${{ matrix.PHP_VERSION }}
PS_DOCKER: ${{ matrix.IMG_DOCKER }}
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -51,7 +51,7 @@ jobs:
PS_VERSION: ${{ env.PS_DOCKER }}
run: |
docker compose -f "docker-compose.yml" up -d --build
bash -c 'while [[ "$(curl -L -s -o /dev/null -w %{http_code} http://localhost/en/)" != "200" ]]; do sleep 5; done'
bash -c 'while [[ "$(curl -L -s -o /dev/null -w %{http_code} http://localhost/)" != "200" ]]; do sleep 5; done'
- name: Composer install
run: composer install
Expand All @@ -64,7 +64,7 @@ jobs:
- name: Upgrade
run: |
docker exec -t prestashop php modules/autoupgrade/cli-upgrade.php --dir=admin-dev --channel=${{ matrix.UPGRADE_CHANNEL }}
docker exec -t prestashop chmod 777 -R /var/www/html/var/cache/dev
docker exec -t prestashop chmod 777 -R /var/www/html/var/cache/
- name: Install dependencies
working-directory: tests/UI/
Expand Down
22 changes: 21 additions & 1 deletion .github/workflows/ui-test/sanity.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,27 @@
{
"include": [
{
"comment": "1.7.8 ~ minor PHP 7.4"
"comment": "1.7.5 ~ major PHP 7.2"
},
{
"PS_VERSION_START": "1.7.5.0",
"PS_VERSION_END": "8.1.7",
"UPGRADE_CHANNEL": "major",
"PHP_VERSION": "7.2",
"IMG_DOCKER": "1.7.5.0"
},
{
"PS_VERSION_START": "1.7.5.1",
"PS_VERSION_END": "8.1.7",
"UPGRADE_CHANNEL": "major",
"PHP_VERSION": "7.2",
"IMG_DOCKER": "1.7.5.1"
},
{
"comment": "@todo 1.7.5.2"
},
{
"comment": "1.7.8 ~ minor PHP 7.2 ~ 7.4"
},
{
"PS_VERSION_START": "1.7.8.10",
Expand Down
2 changes: 1 addition & 1 deletion tests/UI/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: '3.7'

services:
prestashop:
image: prestashop/prestashop:${PS_VERSION}-apache
image: prestashop/prestashop:${PS_VERSION}
container_name: prestashop
depends_on:
- mysql
Expand Down

0 comments on commit b6e71d7

Please sign in to comment.