Skip to content

Commit c1e1143

Browse files
committed
Update README and CI to use headless chrome in https for tests
1 parent 49695fd commit c1e1143

File tree

3 files changed

+13
-13
lines changed

3 files changed

+13
-13
lines changed

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ before_script:
4747
- (cd tests/Application && bin/console cache:warmup -vvv)
4848
- (cd tests/Application && yarn build)
4949

50+
# Install certificates
51+
- $SYLIUS_CACHE_DIR/symfony server:ca:install
52+
5053
# Downloading Symfony CLI
5154
- |
5255
if [ ! -f $SYLIUS_CACHE_DIR/symfony ]; then

README.md

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -132,21 +132,18 @@ composer suite
132132

133133
To run Behat's Javascript scenarios you need to setup Selenium and Chromedriver. Do the following:
134134

135-
1. Download [Chromedriver](https://sites.google.com/a/chromium.org/chromedriver/)
135+
1. Start Headless Chrome:
136136

137-
2. Download [Selenium Standalone Server](https://www.seleniumhq.org/download/)
137+
```bash
138+
google-chrome-stable --enable-automation --disable-background-networking --no-default-browser-check --no-first-run --disable-popup-blocking --disable-default-apps --allow-insecure-localhost --disable-translate --disable-extensions --no-sandbox --enable-features=Metal --headless --remote-debugging-port=9222 --window-size=2880,1800 --proxy-server='direct://' --proxy-bypass-list='*' http://127.0.0.1
139+
```
138140

139-
3. Run Selenium with Chromedriver
141+
2. Install SSL certificates (only once needed) and run test application's webserver on `127.0.0.1:8080`:
140142

141-
```bash
142-
java -Dwebdriver.chrome.driver=chromedriver -jar selenium-server-standalone.jar
143-
```
144-
145-
4. Remember that the test application webserver must be up and running as described above:
146-
147-
```bash
148-
(cd tests/Application && symfony server:start --port=8080 --dir=public --daemon)
149-
```
143+
```bash
144+
symfony server:ca:install
145+
APP_ENV=test symfony server:start --port=8080 --dir=tests/Application/public --daemon
146+
```
150147

151148
License
152149
-------

behat.yml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ default:
1313

1414
Behat\MinkExtension:
1515
files_path: "%paths.base%/vendor/sylius/sylius/src/Sylius/Behat/Resources/fixtures/"
16-
base_url: "http://localhost:8080/"
16+
base_url: "https://127.0.0.1:8080/"
1717
default_session: symfony
1818
javascript_session: chrome_headless
1919
sessions:

0 commit comments

Comments
 (0)