mirror of
https://github.com/bevyengine/bevy
synced 2024-12-14 23:32:28 +00:00
21dc3abe1b
# Objective - Test mobile example on real devices ## Solution - Use [BrowserStack](https://www.browserstack.com) to have access to [real devices](https://www.browserstack.com/list-of-browsers-and-platforms/app_automate) - [App Automate](https://www.browserstack.com/app-automate) to run the example - [App Percy](https://www.browserstack.com/app-percy) to compare the screenshot - Added a daily/manual CI job that will build for iOS and Android, send the apps to BrowserStack, run the app on one iOS device and one Android device, capture a screenshot, send it for visual validation, and archive it in the GitHub action Example run: https://github.com/mockersf/bevy/actions/runs/4521883534 They currently have a bug with the settings to view snapshots, they should be public. I'll raise it to them, and if they don't fix it in time it's possible to work around for everyone to view the results through their API. @cart to get this to work, you'll need - to set up an account on BrowserStack - add the secrets `BROWSERSTACK_USERNAME` and `BROWSERSTACK_ACCESS_KEY` to the Bevy repo - create a project in Percy - add the secret `PERCY_TOKEN` to the Bevy repo and modify the project name line 122 in the `Daily.yml` file
35 lines
No EOL
845 B
JavaScript
35 lines
No EOL
845 B
JavaScript
exports.config = {
|
|
user: process.env.BROWSERSTACK_USERNAME,
|
|
key: process.env.BROWSERSTACK_ACCESS_KEY,
|
|
|
|
updateJob: false,
|
|
specs: [
|
|
'./specs/screenshot.js'
|
|
],
|
|
exclude: [],
|
|
|
|
capabilities: [{
|
|
project: "Bevy Example",
|
|
build: 'Bevy Example Runner',
|
|
name: 'run_example',
|
|
device: process.env.DEVICE || 'Samsung Galaxy S23',
|
|
os_version: process.env.OS_VERSION || "13.0",
|
|
app: process.env.BROWSERSTACK_APP_ID,
|
|
'browserstack.debug': true,
|
|
orientation: 'LANDSCAPE'
|
|
}],
|
|
|
|
logLevel: 'info',
|
|
coloredLogs: true,
|
|
screenshotPath: './screenshots/',
|
|
baseUrl: '',
|
|
waitforTimeout: 10000,
|
|
connectionRetryTimeout: 90000,
|
|
connectionRetryCount: 3,
|
|
|
|
framework: 'mocha',
|
|
mochaOpts: {
|
|
ui: 'bdd',
|
|
timeout: 20000
|
|
}
|
|
}; |