Skip to content

Commit

Permalink
Merge pull request #576 from Satellite-im/luis/discovery-disable
Browse files Browse the repository at this point in the history
chore(appium): pass discovery disable flag on CI
  • Loading branch information
luisecm authored Dec 18, 2023
2 parents c61ef09 + f656e7d commit 795695c
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 7 deletions.
2 changes: 1 addition & 1 deletion config/wdio.mac.app.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export const config: WebdriverIO.Config = {
platformName: "mac",
"appium:automationName": MACOS_DRIVER,
"appium:bundleId": MACOS_BUNDLE_ID,
"appium:arguments": ["--path", homedir() + "/.uplink"],
"appium:arguments": ["--discovery", "disable", "--path", homedir() + "/.uplink"],
"appium:systemPort": 4724,
"appium:prerun": {
command: 'do shell script "rm -rf ~/.uplink"',
Expand Down
2 changes: 1 addition & 1 deletion config/wdio.mac.ci.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export const config: WebdriverIO.Config = {
platformName: "mac",
"appium:automationName": MACOS_DRIVER,
"appium:bundleId": MACOS_BUNDLE_ID,
"appium:arguments": ["--path", homedir() + "/.uplink"],
"appium:arguments": ["--discovery", "disable", "--path", homedir() + "/.uplink"],
"appium:systemPort": 4724,
"appium:prerun": {
command: 'do shell script "rm -rf ~/.uplink"',
Expand Down
2 changes: 1 addition & 1 deletion config/wdio.mac.multiremote.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export const config: WebdriverIO.Config = {
platformName: "mac",
"appium:automationName": MACOS_DRIVER,
"appium:bundleId": MACOS_USER_A_BUNDLE_ID,
"appium:arguments": ["--path", homedir() + "/.uplink"],
"appium:arguments": ["--discovery", "disable", "--path", homedir() + "/.uplink"],
"appium:systemPort": 4725,
"appium:prerun": {
command: 'do shell script "rm -rf ~/.uplink && rm -rf ~/.uplinkUserB"',
Expand Down
1 change: 1 addition & 0 deletions config/wdio.windows.app.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ export const config: WebdriverIO.Config = {
"appium:deviceName": "WindowsPC",
"appium:automationName": "windows",
"appium:app": join(process.cwd(), "\\apps\\bin\\uplink.exe"),
"appium:appArguments": "--discovery disable",
"ms:waitForAppLaunch": 30,
"appium:prerun": {
command: 'If (Test-Path $home/.uplink/.user) {Remove-Item -Recurse -Force $home/.uplink/.user} Else { Break }',
Expand Down
1 change: 1 addition & 0 deletions config/wdio.windows.ci.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ export const config: WebdriverIO.Config = {
"appium:deviceName": "WindowsPC",
"appium:automationName": "windows",
"appium:app": join(process.cwd(), "\\apps\\bin\\uplink.exe"),
"appium:appArguments": "--discovery disable",
"ms:waitForAppLaunch": 50,
"appium:prerun": {
command: 'If (Test-Path $home/.uplink/.user) {Remove-Item -Recurse -Force $home/.uplink/.user} Else { Break }',
Expand Down
4 changes: 2 additions & 2 deletions config/wdio.windows.multiremote.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export const config: WebdriverIO.Config = {
"appium:systemPort": 4725,
"appium:createSessionTimeout": 40000,
"ms:waitForAppLaunch": 50,
"appium:appArguments": "--path " + join(process.cwd(), "\\apps\\ChatUserA"),
"appium:appArguments": "--discovery disable --path " + join(process.cwd(), "\\apps\\ChatUserA"),
"appium:prerun": {
command: `If (Test-Path ${userACacheFolder}) {Remove-Item -Recurse -Force ${userACacheFolder}} Else { Break }`,
},
Expand All @@ -71,7 +71,7 @@ export const config: WebdriverIO.Config = {
"appium:systemPort": 4726,
"appium:createSessionTimeout": 40000,
"ms:waitForAppLaunch": 50,
"appium:appArguments": "--path " + join(process.cwd(), "\\apps\\ChatUserB"),
"appium:appArguments": "--discovery disable --path " + join(process.cwd(), "\\apps\\ChatUserB"),
"appium:prerun": {
command: `If (Test-Path ${userBCacheFolder}) {Remove-Item -Recurse -Force ${userBCacheFolder}} Else { Break }`,
},
Expand Down
2 changes: 1 addition & 1 deletion config/wdio.windows.onetime.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export const config: WebdriverIO.Config = {
"appium:deviceName": "WindowsPC",
"appium:automationName": "windows",
"appium:app": join(process.cwd(), "\\apps\\bin\\uplink.exe"),
"appium:appArguments": "--path " + join(process.cwd(), "\\apps\\onetimescript2") + " trace2",
"appium:appArguments": "--discovery disable --path " + join(process.cwd(), "\\apps\\onetimescript2") + " trace2",
"appium:prerun": {
command: 'If (Test-Path $home/.uplink/.user) {Remove-Item -Recurse -Force $home/.uplink/.user} Else { Break }',
},
Expand Down
7 changes: 6 additions & 1 deletion tests/helpers/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,12 @@ export async function launchSecondApplication() {
await driver[USER_A_INSTANCE].executeScript("macos: launchApp", [
{
bundleId: MACOS_USER_B_BUNDLE_ID,
arguments: ["--path", homedir() + "/.uplinkUserB"],
arguments: [
"--discovery",
"disable",
"--path",
homedir() + "/.uplinkUserB",
],
},
]);
await browser.pause(5000);
Expand Down

0 comments on commit 795695c

Please sign in to comment.