Skip to content

Commit

Permalink
Fixed CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Progi1984 committed Jan 22, 2024
1 parent 825df30 commit 3029fe0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 18 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/ui-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,10 @@ jobs:
run: npm install && npm run build

- name: Start containers
run: docker-compose -f "docker-compose.yml" up -d --build
run: |
docker-compose -f "docker-compose.yml" up -d --build
while ! nc -z localhost 8000; do sleep 1; done;
working-directory: tests/UI/

- name: Install dependencies
run: npm ci
Expand All @@ -43,5 +46,5 @@ jobs:
if: always()
with:
name: playwright-report
path: playwright-report/
path: tests/UI/reports/
retention-days: 30
11 changes: 6 additions & 5 deletions tests/UI/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
version: '3.7'

services:
prestashop:
image: prestashop/prestashop-flashlight:${PS_VERSION}
container_name: prestashop
depends_on:
mysql:
condition: service_healthy
depends_on:
- mysql
environment:
- DEBUG_MODE=true
- PS_DOMAIN=localhost:8000
volumes:
- type: bind
# Local Path
Expand All @@ -15,7 +17,6 @@ services:
target: /var/www/html/modules/blockwishlist
ports:
- 8000:80

mysql:
image: mariadb:lts
container_name: prestashop-mysql
Expand All @@ -38,4 +39,4 @@ services:
- MYSQL_PASSWORD=prestashop
- MYSQL_ROOT_PASSWORD=prestashop
- MYSQL_PORT=3306
- MYSQL_DATABASE=prestashop
- MYSQL_DATABASE=prestashop
14 changes: 3 additions & 11 deletions tests/UI/playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import path from 'path';

function loadGlobal(): void {
global.FO = {
URL: process.env.URL_FO || 'http://localhost/prestashop/',
URL: process.env.URL_FO || 'http://localhost:8000/',
};

/*
Expand All @@ -14,8 +14,8 @@ function loadGlobal(): void {

global.BO = {
URL: process.env.URL_BO || `${global.FO.URL}admin-dev/`,
EMAIL: process.env.LOGIN || 'demo@prestashop.com',
PASSWD: process.env.PASSWD || 'Correct Horse Battery Staple',
EMAIL: process.env.LOGIN || 'admin@prestashop.com',
PASSWD: process.env.PASSWD || 'prestashop',
FIRSTNAME: process.env.FIRSTNAME || 'Marc',
LASTNAME: process.env.LASTNAME || 'Beier',
};
Expand Down Expand Up @@ -64,14 +64,6 @@ function loadGlobal(): void {
smtpServer: process.env.SMTP_SERVER || 'localhost',
silent: true,
};

global.keycloakConfig = {
keycloakExternalUrl: process.env.KEYCLOAK_URL_EXTERNAL || 'http://127.0.0.1:8003',
keycloakInternalUrl: process.env.KEYCLOAK_URL_INTERNAL || 'http://keycloak:8080',
keycloakAdminUser: process.env.KEYCLOAK_ADMIN_USER || 'admin',
keycloakAdminPass: process.env.KEYCLOAK_ADMIN_PASS || 'admin',
keycloakClientId: process.env.KEYCLOAK_CLIENT_ID || 'KEYCLOAK_CLIENT_ID',
};
}

/**
Expand Down

0 comments on commit 3029fe0

Please sign in to comment.