Skip to content

[DX-3449] test: new test account #353

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion sample/Assets/Editor/MacBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ private static BuildPlayerOptions CreateBuildPlayerOptions(string buildPath, Bui
"Assets/Scenes/ZkEvmGetTransactionReceipt.unity",
"Assets/Scenes/ZkEvmSendTransaction.unity",
"Assets/Scenes/ImxNftTransfer.unity",
"Assets/Scenes/ZkEVMSignTypedData.unity"
"Assets/Scenes/ZkEVMSignTypedData.unity",
"Assets/Scenes/SetCallTimeout.unity"
},
locationPathName = buildPath,
target = BuildTarget.StandaloneOSX,
Expand Down
3 changes: 2 additions & 1 deletion sample/Assets/Editor/MobileBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ private static BuildPlayerOptions CreateBuildPlayerOptions(string buildPath, Bui
"Assets/Scenes/ZkEvmGetTransactionReceipt.unity",
"Assets/Scenes/ZkEvmSendTransaction.unity",
"Assets/Scenes/ImxNftTransfer.unity",
"Assets/Scenes/ZkEVMSignTypedData.unity"
"Assets/Scenes/ZkEVMSignTypedData.unity",
"Assets/Scenes/SetCallTimeout.unity"
},
locationPathName = buildPath,
target = platform,
Expand Down
3 changes: 2 additions & 1 deletion sample/Assets/Editor/WindowsBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ private static BuildPlayerOptions CreateBuildPlayerOptions(string buildPath, Bui
"Assets/Scenes/ZkEvmGetTransactionReceipt.unity",
"Assets/Scenes/ZkEvmSendTransaction.unity",
"Assets/Scenes/ImxNftTransfer.unity",
"Assets/Scenes/ZkEVMSignTypedData.unity"
"Assets/Scenes/ZkEVMSignTypedData.unity",
"Assets/Scenes/SetCallTimeout.unity"
},
locationPathName = buildPath,
target = BuildTarget.StandaloneWindows64,
Expand Down
18 changes: 9 additions & 9 deletions sample/Assets/Scenes/SetCallTimeout.unity
Original file line number Diff line number Diff line change
Expand Up @@ -557,8 +557,8 @@ MonoBehaviour:
m_TargetGraphic: {fileID: 66309839}
m_HandleRect: {fileID: 66309838}
m_Direction: 0
m_Value: 0
m_Size: 1
m_Value: 1
m_Size: 0.9999999
m_NumberOfSteps: 0
m_OnValueChanged:
m_PersistentCalls:
Expand Down Expand Up @@ -739,8 +739,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 1015.1455, y: 0}
m_SizeDelta: {x: 2030.291, y: 0}
m_AnchoredPosition: {x: 1141.847, y: 0}
m_SizeDelta: {x: 2283.694, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &410008536
MonoBehaviour:
Expand Down Expand Up @@ -966,8 +966,8 @@ MonoBehaviour:
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 0}
m_TargetAssemblyTypeName: ZkEvmGetBalance, Assembly-CSharp
- m_Target: {fileID: 1192763474}
m_TargetAssemblyTypeName: SetCallTimeoutScript, Assembly-CSharp
m_MethodName: Cancel
m_Mode: 1
m_Arguments:
Expand Down Expand Up @@ -1052,8 +1052,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 1015.1455, y: 0}
m_SizeDelta: {x: 2030.291, y: 0}
m_AnchoredPosition: {x: 1141.847, y: 0}
m_SizeDelta: {x: 2283.694, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &783923066
MonoBehaviour:
Expand Down Expand Up @@ -1195,7 +1195,7 @@ MonoBehaviour:
m_TargetGraphic: {fileID: 1741513414}
m_HandleRect: {fileID: 1741513413}
m_Direction: 2
m_Value: 0
m_Value: 1
m_Size: 1
m_NumberOfSteps: 0
m_OnValueChanged:
Expand Down
4 changes: 2 additions & 2 deletions sample/Tests/src/fetch_otp.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
from mailslurp_client.api import InboxControllerApi, WaitForControllerApi
import re

INBOX_ID = "7cff2120-f684-4f31-886f-b29ca2400247"
EMAIL = "7cff2120-f684-4f31-886f-b29ca2400247@mailslurp.net"
INBOX_ID = "a1369a61-9149-4499-a75e-610523e2baa7"
EMAIL = "a1369a61-9149-4499-a75e-610523e2baa7@mailslurp.net"

def get_mailslurp_client():
configuration = mailslurp_client.Configuration()
Expand Down
10 changes: 7 additions & 3 deletions sample/Tests/test/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
from alttester import *

class TestConfig:
EMAIL = "7cff2120-f684-4f31-886f-b29ca2400247@mailslurp.net"
PASSPORT_ID="email|67365ff8219c150ace187e28"
WALLET_ADDRESS = "0xdd571aa2f37f6b5166b14c6e43f1114bf444cdd8"
EMAIL = "a1369a61-9149-4499-a75e-610523e2baa7@mailslurp.net"
PASSPORT_ID="email|673a7cc7219c150ace38cf60"
WALLET_ADDRESS = "0xf629c9f0fee71cce1b21a6e5b0db8df2e8cd7354"

class UnityTest(unittest.TestCase):

Expand All @@ -33,6 +33,10 @@ def test_0_other_functions(self):
output = self.altdriver.find_object(By.NAME, "Output")
self.assertEqual("Set call timeout to: 600000ms", output.get_text())

# Go back to authenticated scene
self.altdriver.find_object(By.NAME, "CancelButton").tap()
self.altdriver.wait_for_current_scene_to_be("AuthenticatedScene")

def test_1_passport_functions(self):
output = self.altdriver.find_object(By.NAME, "Output")

Expand Down
18 changes: 16 additions & 2 deletions sample/Tests/test_windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ function Run-Pytest {
[string]$testFile
)
Write-Output "Running pytest for $testFile..."
Start-Process -FilePath "pytest" -ArgumentList $testFile -NoNewWindow -PassThru | Wait-Process
$process = Start-Process -FilePath "pytest" -ArgumentList "-x", $testFile -NoNewWindow -PassThru -Wait
if ($process.ExitCode -ne 0) {
Write-Output "Test failed for $testFile. Stopping execution."
exit $process.ExitCode
}
}

# Function to stop Chrome if it's running
Expand Down Expand Up @@ -95,7 +99,17 @@ function Login {
function Logout {
# Start Chrome for remote debugging
Write-Output "Starting Chrome..."
$chromePath = (Get-Command chrome.exe).Source
$chromePath = "C:\Program Files\Google\Chrome\Application\chrome.exe"

if (-not (Test-Path $chromePath)) {
$chromePath = "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe"
}

if (-not (Test-Path $chromePath)) {
Write-Output "Chrome executable not found."
exit
}

Start-Process -FilePath $chromePath -ArgumentList "--remote-debugging-port=9222"

Write-Output "Running python script to logout..."
Expand Down
Loading