-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 1a57c40
Showing
6 changed files
with
119 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/node_modules | ||
/package-lock.json |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
import {join} from 'path'; | ||
|
||
exports.config = { | ||
|
||
autoCompileOpts: { | ||
autoCompile: true, | ||
tsNodeOpts: { | ||
transpileOnly: true, | ||
project: 'test/tsconfig.json' | ||
} | ||
}, | ||
// | ||
// ==================== | ||
// Runner Configuration | ||
// ==================== | ||
// | ||
port: 4723, | ||
specs: ["./test/specs/android/*.ts"], | ||
// Patterns to exclude. | ||
exclude: [], | ||
// | ||
// ============ | ||
// Capabilities | ||
// ============ | ||
// | ||
maxInstances: 1, | ||
capabilities: [ | ||
{ | ||
platformName: 'Android', | ||
maxInstances: 1, | ||
'appium:deviceName': 'Pixel_3_10.0', | ||
'appium:platformVersion': '10.0', | ||
'appium:orientation': 'PORTRAIT', | ||
'appium:automationName': 'UiAutomator2', | ||
'appium:app': join(process.cwd(), './app/Android.SauceLabs.Mobile.Sample.app.2.7.1.apk'), | ||
// @ts-ignore | ||
'appium:appWaitActivity': 'com.swaglabsmobileapp.MainActivity', | ||
'appium:newCommandTimeout': 240, | ||
}, | ||
], | ||
// | ||
// =================== | ||
// Test Configurations | ||
// =================== | ||
logLevel: "info", | ||
bail: 0, | ||
baseUrl: "http://localhost", | ||
waitforTimeout: 10000, | ||
connectionRetryTimeout: 120000, | ||
connectionRetryCount: 3, | ||
services: [ | ||
[ | ||
"appium", | ||
{ | ||
args: { | ||
address: "localhost", | ||
port: 4723, | ||
}, | ||
logPath: "./", | ||
}, | ||
], | ||
], | ||
framework: "mocha", | ||
reporters: ["spec"], | ||
mochaOpts: { | ||
ui: "bdd", | ||
timeout: 60000, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"name": "webdriverio-tests", | ||
"version": "0.1.0", | ||
"description": "", | ||
"private": true, | ||
"keywords": [], | ||
"author": "", | ||
"license": "ISC", | ||
"devDependencies": { | ||
"@wdio/appium-service": "^7.25.1", | ||
"@wdio/cli": "^7.25.1", | ||
"@wdio/local-runner": "^7.25.1", | ||
"@wdio/mocha-framework": "^7.25.1", | ||
"@wdio/spec-reporter": "^7.25.1", | ||
"appium": "^2.0.0-beta.44", | ||
"appium-uiautomator2-driver": "^2.7.0", | ||
"appium-xcuitest-driver": "^4.12.0", | ||
"chromedriver": "^106.0.1", | ||
"wdio-chromedriver-service": "^8.0.0", | ||
"ts-node": "^10.8.0", | ||
"typescript": "^4.6.4" | ||
}, | ||
"scripts": { | ||
"wdioAndroid": "wdio run config/wdio-android.conf.ts" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
describe("My Login Demo", () => { | ||
beforeEach(async () => { | ||
await $("~open menu").click(); | ||
await $('//*[@text="Log In"]').click(); | ||
}); | ||
|
||
it("should not login with invalid credentials", async () => { | ||
|
||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"compilerOptions": { | ||
"moduleResolution": "node", | ||
"types": [ | ||
"node", | ||
"webdriverio/async", | ||
"@wdio/mocha-framework", | ||
"expect-webdriverio" | ||
], | ||
"target": "es2019" | ||
} | ||
} |