Skip to content

Commit 3a975ff

Browse files
committed
asd
1 parent 9663688 commit 3a975ff

File tree

2 files changed

+41
-1
lines changed

2 files changed

+41
-1
lines changed

.github/workflows/test.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,43 @@ jobs:
8585
cd ./apps/frontend
8686
pnpm unit-test
8787
88+
89+
test-webdriver-working:
90+
runs-on: ubuntu-latest
91+
92+
steps:
93+
- name: Checkout code
94+
uses: actions/checkout@v4
95+
96+
- name: Install pnpm
97+
uses: pnpm/action-setup@v4
98+
with:
99+
version: 9.1.4
100+
101+
- name: Install dependencies
102+
run: |
103+
cd ./apps/frontend
104+
pnpm i
105+
106+
- name: Install Chrome WebDriver
107+
uses: nanasess/setup-chromedriver@v2
108+
with:
109+
chromedriver-version: '130.0.6723.116'
110+
111+
- name: Install Edge
112+
uses: browser-actions/setup-edge@v1
113+
with:
114+
edge-version: stable
115+
116+
- name: Install Geckodriver
117+
uses: browser-actions/setup-geckodriver@latest
118+
119+
120+
- name: Run Browser Test
121+
run: |
122+
cd ./apps/frontend
123+
pnpm browser-test -- -t "webdriver installed correctly"
124+
88125
test-docker-compose:
89126
runs-on: ubuntu-latest
90127

apps/frontend/__tests__/browser-tests/browser.test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@ const ETERNAL_JWT = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3OD
1010
const CHROME_OPTIONS = new ChromeOptions()
1111
.addArguments("--headless=new") as ChromeOptions; // uncomment locally to see the steps in action
1212
const EDGE_OPTIONS = new EdgeOptions()
13+
.setBinaryPath("/opt/hostedtoolcache/msedge/stable/x64/msedge")
1314
.addArguments("--headless=new") as EdgeOptions;
15+
1416
const FIREFOX_OPTIONS = new FirefoxOptions()
17+
.setBinary("/opt/hostedtoolcache/geckodriver/0.35.0/x64/geckodriver")
1518
.addArguments("--headless") as FirefoxOptions;
1619

1720
const builder = new Builder()
@@ -34,7 +37,7 @@ describe.each([Browser.CHROME, Browser.EDGE, Browser.FIREFOX])("%s driver test",
3437
await driver.quit();
3538
})
3639

37-
describe.skip("webdriver installed correctly", () => {
40+
describe("webdriver installed correctly", () => {
3841
it("does google search", async () => {
3942
await driver.get('http://www.google.com');
4043
await driver.findElement(By.name('q')).sendKeys('webdriver', Key.RETURN);

0 commit comments

Comments
 (0)