You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can configure a secure tunnel in HyperExecute to test applications that are:
40
41
41
-
# Tunnel Configuration
42
+
- Hosted locally on your system, or
43
+
- Behind a private network/firewall.
42
44
43
-
***
45
+
## Prerequisites
46
+
- HyperExecute YAML file -> HyperExecute supports multiple ways of setting up tunnels directly from your YAML configuration. You can use any version of [YAML](https://www.lambdatest.com/support/docs/hyperexecute-yaml-parameters/) to pass the Tunnel parameters.
47
+
-[HyperExecute CLI](/support/docs/hyperexecute-cli-run-tests-on-hyperexecute-grid/) to trigger your tests.
44
48
45
-
## How to Configure Tunnel with HyperExecute?
46
-
47
-
> You can use any version of YAML to pass the Tunnel Parameters.
48
-
49
-
If you want to use a tunnel with HyperExecute, you will have to download the [HyperExecute CLI](/support/docs/hyperexecute-cli-run-tests-on-hyperexecute-grid/) and configure it.
50
-
51
-
There are 3 ways to use a tunnel in HyperExecute:
49
+
## Ways to Use Tunnel in HyperExecute
50
+
There are 3 main ways to use a tunnel in HyperExecute:
52
51
53
52
### 1. Simple `tunnel` Connection
53
+
Enable tunnel directly by setting the `tunnel` flag to `true` in your HyperExecute YAML file. The HyperExecute CLI will launch a tunnel as sub process for accessing your applications which are locally hosted or behind a firewall.
54
54
55
-
Set the `tunnel` flag to `true` to enable it. The cli will launch a tunnel as sub process for accessing your applications which are locally hosted or behind a firewall.
56
-
57
-
```bash
55
+
```yaml title="hyperexecute.yaml"
58
56
tunnel: true
59
57
```
58
+
> Recommended if you want to quickly enable tunnel access for locally hosted apps.
60
59
61
60
### 2. Using Existing `tunnel`
61
+
If you already have a running tunnel, you can reuse it by specifying its name to access your applications which are locally hosted or behind a firewall.
62
62
63
-
Specify the list of already running tunnel names which you want to use for accessing your applications which are locally hosted or behind a firewall.
64
-
65
-
```bash
63
+
```yaml title="hyperexecute.yaml"
66
64
tunnelNames: ["lambdatest_tunnel"]
67
65
```
68
66
69
-
### 3. Advanced `tunnel` Configurations
67
+
> Useful when running multiple jobs and you don’t want to spawn new tunnels each time.
70
68
69
+
### 3. Advanced `tunnel` Configurations
71
70
These are the parameters you can use to configure your [tunnel](/support/docs/deep-dive-into-hyperexecute-yaml/#tunnel) settings when running it.
72
71
73
72
| Options | Type | Description |
@@ -79,7 +78,11 @@ These are the parameters you can use to configure your [tunnel](/support/docs/de
79
78
|`systemProxy`| Boolean | Should the tunnel be OS system wide? Default false. |
80
79
|`checkTunnelOnFailure`| Boolean | Check tunnel on failure adds a check on our system to check the tunnel connection if a test fails and the tunnel is set to true. This option will retry the test 2 times if tunnel connection is flaky. |
81
80
82
-
```bash
81
+
> HyperExecute now supports tunnel capabilities for [Maestro](https://www.lambdatest.com/support/docs/hyperexecute-maestro-testing/) tests running on both virtual devices and real devices using the Raw Framework configuration.
> HyperExecute now supports [tunnel capabilities](/support/docs/hyperexecute-how-to-configure-tunnel/) for Maestro tests running on both virtual devices and real devices using the Raw Framework configuration.
139
+
138
140
## Step 5: Generate JUnit XML Report
139
141
1. Update the `runTest.sh` file to include the `--format junit` flag in the maestro test command:
@@ -44,184 +46,84 @@ import {YOUR_LAMBDATEST_USERNAME, YOUR_LAMBDATEST_ACCESS_KEY} from "@site/src/co
44
46
})
45
47
}}
46
48
></script>
47
-
48
-
# Running Playwright with Real Devices on HyperExecute
49
-
50
-
This guide details how to execute your **Playwright Real Device** tests on **HyperExecute**:
51
-
<!--
52
-
- [**Using Local System**](/support/docs/junit-on-hyperexecute-grid/#1-testing-using-local-system) - You can use your own local machine to execute tests.
53
-
- [**Using Gitpod Platform**](/support/docs/junit-on-hyperexecute-grid/#2-testing-using-gitpod) - Execute tests using GitPod. (Requires a [Gitpod](https://gitpod.io/login/) account) -->
54
-
55
-
<!-- ## Testing Using Local System
56
-
57
-
Follow the step-by-step guide to execute your test on HyperExecute. -->
49
+
This guide explains how to run your **Playwright** tests on **Real devices (Android and iOS)** using HyperExecute:
58
50
59
51
## Prerequisites
60
-
61
-
To run the Tests on HyperExecute from your Local System, you are required:
52
+
Before running your tests, ensure you have:
62
53
63
54
- Your LambdaTest [Username and Access key](/support/docs/hyperexecute-how-to-get-my-username-and-access-key/)
64
-
-[HyperExecute YAML](/support/docs/hyperexecute-yaml-version0.2/) file which contains all the necessary instructions.
55
+
-[HyperExecute YAML](/support/docs/hyperexecute-yaml-version0.2/) file with the test configuration.
65
56
-[HyperExecute CLI](/support/docs/hyperexecute-cli-run-tests-on-hyperexecute-grid/) in order to initiate a test execution Job .
66
-
- Setup the [Environmental Variable](/support/docs/hyperexecute-environment-variable-setup/)
67
57
68
-
## Step 1: Setup Your Test Suite
69
-
70
-
You can use your own project to configure and test it. For demo purposes, we are using the sample repository.
58
+
## Step 1: Set Up Your Test Project
59
+
You can use your own Playwright project or try the sample repo:. For demo purposes, we are using the sample repository.
71
60
72
61
:::tip Sample repo
73
-
74
62
Download or Clone the code sample for the Playwright Real Device from the LambdaTest GitHub repository to run the tests on the HyperExecute.
75
63
76
64
<ahref="https://github.com/LambdaTest/LambdaTest-HyperExecute-Playwright-Appium-Sample"className="github__anchor"><img loading="lazy" src={require('../assets/images/icons/github.png').default} alt="Image" className="doc_img"/> View on GitHub</a>
77
-
78
65
:::
79
66
80
-
### Configure the Capabilities
81
-
82
-
Configure the desired capabilities based on your test requirements. For example:
83
-
84
-
```bash
85
-
const capabilities = {
86
-
'browserName': 'Chrome', #Browsers allowed: `Chrome`, `MicrosoftEdge`, `pw-chromium`, `pw-firefox` and `pw-webkit`
87
-
'browserVersion': 'latest',
88
-
'LT:Options': {
89
-
'platform': 'android',
90
-
'build': 'Playwright HyperExecute Build',
91
-
'name': 'Playwright HyperExecute Test',
92
-
'user': '<your_lambdatest_user_name>',
93
-
'accessKey': '<your_lambdatest_access_key>',
94
-
# 'network': true,
95
-
'video': true,
96
-
'console': true
97
-
}
98
-
}
99
-
```
67
+
### Configure Desired Capabilities
68
+
Update your test configuration with the required capabilities.
> You can also use **dev** and **beta** browser versions. To generate capabilities for your test requirements, you can use our inbuilt 🔗 [Capabilities Generator Tool](https://www.lambdatest.com/capabilities-generator/).
102
85
103
86
### Configure the CDP URL
87
+
You will have to update the **CDP (Chrome DevTools Protocol) URL** which is a protocol used for communication between the browser and the developer tools.
104
88
105
-
- You will have to update the **CDP (Chrome DevTools Protocol) URL** which is a protocol used for communication between the browser and the developer tools.
After cloning / downloading the sample repo, you need to setup the CLI and the environment variables.
116
-
117
-
### Download the HyperExecute CLI
118
-
119
-
The CLI is used for triggering the tests on HyperExecute. It is recommend to download the CLI binary on the host system and keep it in the root directory of the suite to perform the tests on HyperExecute.
95
+
## Step 2: Download the CLI in your Project
96
+
The CLI is used for triggering the tests on HyperExecute. It is recommend to download the CLI binary on the host system and keep it in the root directory of the project to execute the tests on HyperExecute.
120
97
121
98
You can download the CLI for your desired platform from the below mentioned links:
122
99
123
-
|Platform| HyperExecute CLI |
100
+
|Host Machine| HyperExecute CLI |
124
101
| ---------| ---------------- |
125
102
| Windows |https://downloads.lambdatest.com/hyperexecute/windows/hyperexecute.exe|
| Linux |https://downloads.lambdatest.com/hyperexecute/linux/hyperexecute|
128
105
129
-
### Setup Environment Variable
130
-
131
-
Now, you need to export your environment variables *LT_USERNAME* and *LT_ACCESS_KEY* that are available in the [LambdaTest Profile page](https://accounts.lambdatest.com/detail/profile).
132
-
133
-
Run the below mentioned commands in your terminal to setup the CLI and the environment variables.
134
-
135
-
import Tabs from '@theme/Tabs';
136
-
import TabItem from '@theme/TabItem';
106
+
## Step 3: Configure YAML in your Test Suite
107
+
Use the sample YAML below to configure your execution:
Configure your YAML file as per your use cases using **key value** pairs.
166
-
167
-
In this sample YAML file, we have mentioned:
168
-
169
-
-**version** of the YAML file
170
-
-**runson** flag to specify the operating system
171
-
-**Mode of execution** is [Autosplit](/support/docs/hyperexecute-auto-split-strategy/). You can also opt for [Matrix](/support/docs/hyperexecute-matrix-multiplexing-strategy/) or [Hybrid](/support/docs/hyperexecute-hybrid-strategy/) mode.
To Run test on Mobile Containers in a Particular Region
223
125
224
-
```bash
126
+
```yaml title="hyperexecute.yaml"
225
127
dynamicAllocation: true
226
128
227
129
framework:
@@ -231,9 +133,7 @@ framework:
231
133
region: ap # supported regions -> ap, eu, us
232
134
reservation: false
233
135
```
234
-
235
136
- If **`reservation : false`**, it means that it will allocate the device from any region. If you want to allocate the device of any specific region, keep the **`reservation : true`**.
236
-
237
137
:::
238
138
239
139
## Step 4: Execute your Test Suite
@@ -242,22 +142,12 @@ framework:
242
142
243
143
Run the below command in your terminal at the root folder of the project:
0 commit comments