webship-js 1.0.25 → 1.0.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -47,7 +47,7 @@ commands:
47
47
  wget https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb
48
48
  sudo dpkg -i google-chrome-stable_${CHROME_VERSION}_amd64.deb
49
49
  rm google-chrome-stable_${CHROME_VERSION}_amd64.deb
50
-
50
+
51
51
  ## Install/Update Chrome Driver.
52
52
  - run:
53
53
  name: Install/Update Chrome Driver
@@ -64,9 +64,9 @@ commands:
64
64
  - run:
65
65
  name: Run Selenium Standalone server
66
66
  command: |
67
- if [[ ! -f /home/circleci/selenium-server-4.1.2.jar ]]; then wget -O /home/circleci/selenium-server-4.1.2.jar https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.1.0/selenium-server-4.1.2.jar; fi
67
+ if [[ ! -f /home/circleci/selenium-server-4.4.0.jar ]]; then wget -O /home/circleci/selenium-server-4.4.0.jar https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.4.0/selenium-server-4.4.0.jar; fi
68
68
  cd /home/circleci/
69
- java -jar selenium-server-4.1.2.jar standalone
69
+ java -jar selenium-server-4.4.0.jar standalone
70
70
  background: true
71
71
 
72
72
  jobs:
@@ -8,29 +8,14 @@ jobs:
8
8
  runs-on: ubuntu-latest
9
9
 
10
10
  env:
11
- TEST_BASE_URL: http://localhost:8080
11
+ TEST_BASE_URL: http://localhost:808
12
+ SELENIUM_HOST: http://selenium:4444/wd/hub
12
13
 
13
14
  steps:
14
15
  - name: Install Chrome
15
16
  run: |
16
- sudo apt install libu2f-udev
17
- sudo apt-get install libappindicator1 fonts-liberation libgbm1 libgtk-3-0 xdg-utils
18
- export CHROME_BIN=/usr/bin/google-chrome
19
- CHROME_VERSION="121.0.6167.85-1"
20
- wget https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb
21
- sudo dpkg -i google-chrome-stable_${CHROME_VERSION}_amd64.deb
22
- rm google-chrome-stable_${CHROME_VERSION}_amd64.deb
23
-
24
- - name: Install/Update Chrome Driver
25
- run: |
26
- CHROME_DRIVER_VERSION=$(wget -qO- chromedriver.storage.googleapis.com/LATEST_RELEASE);
27
- echo $CHROME_DRIVER_VERSION;
28
- wget http://chromedriver.storage.googleapis.com/$CHROME_DRIVER_VERSION/chromedriver_linux64.zip
29
- unzip chromedriver_linux64.zip
30
- chmod +x chromedriver
31
- mkdir -p $HOME/.composer/vendor/bin
32
- mv -f chromedriver $HOME/.composer/vendor/bin/
33
- rm chromedriver_linux64.zip
17
+ wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
18
+ sudo dpkg -i google-chrome-stable_current_amd64.deb
34
19
 
35
20
  - uses: actions/checkout@v3
36
21
  - name: Use Node.js
@@ -40,8 +25,8 @@ jobs:
40
25
 
41
26
  - name: Run Selenium Standalone server
42
27
  run: |
43
- wget https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.1.0/selenium-server-4.1.2.jar
44
- java -jar selenium-server-4.1.2.jar -role node -hub http://localhost:4444
28
+ wget https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.4.0/selenium-server-4.4.0.jar
29
+ java -jar selenium-server-4.4.0.jar standalone --port 4444
45
30
 
46
31
  - name: Install
47
32
  run: yarn install
package/.travis-ci.yml CHANGED
@@ -5,7 +5,7 @@ jdk:
5
5
  - openjdk-11-jre
6
6
 
7
7
  before_script:
8
- - docker run -d -p 4444:4444 -v /dev/shm:/dev/shm selenium/standalone-firefox:4.0.0-rc-1-prerelease-20210618
8
+ - docker run -d -p 4444:4444 -v /dev/shm:/dev/shm selenium/standalone-firefox:4.4.0-rc-1-prerelease-20210618
9
9
  - docker ps
10
10
 
11
11
  script:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "webship-js",
3
- "version": "1.0.25",
3
+ "version": "1.0.28",
4
4
  "description": "Webship JS automated functional testing.",
5
5
  "main": "index.js",
6
6
  "directories": {
@@ -5,7 +5,7 @@ Feature: An example to select option from drop down list
5
5
 
6
6
  Scenario: Check of selecting option from drop down list
7
7
  Given I am on "/test--when--i-select-option-from-dropdownlist.html"
8
- When I select "saab" from "#cars"
8
+ When I select "saab" from "cars"
9
9
  When I press "Check select"
10
10
  Then I should see "Option ( Saab ) has been selected successfully"
11
11
 
@@ -194,7 +194,10 @@ When(/^(I|we)* fill in the following:$/, function (pronoundCase, table) {
194
194
  */
195
195
  When(/^(I|we)* select "([^"]*)?" from "([^"]*)?"$/, function (pronoundCase, option, dropdownlist) {
196
196
 
197
- return browser.click('select' + dropdownlist + ' option[value=' + option + ']');
197
+ browser.waitForElementVisible('css selector', 'select[name="' + dropdownlist + '"]')
198
+ .click('select[name="' + dropdownlist + '"]')
199
+ .click('select[name="' + dropdownlist + '"]' + ' option[value=' + option + ']')
200
+ .click('select[name="' + dropdownlist + '"]');
198
201
  });
199
202
 
200
203
  /**