store screenshots in _generated_ folder

This commit is contained in:
Vadim 2023-12-27 21:24:36 +01:00
parent be2aa45afc
commit 048ab4e308
5 changed files with 37 additions and 29 deletions

View file

@ -10,8 +10,8 @@ As a user I want to see the most relevant screenshots in the store, so that I ca
- Metering screen
1. Reflected light metering mode*
2. Incident light metering mode* **
1. Reflected light metering mode\*
2. Incident light metering mode\* \*\*
3. Opened ISO picker
- Settings screen
@ -24,11 +24,41 @@ As a user I want to see the most relevant screenshots in the store, so that I ca
1. Just the screen
2. Opened equipment profile ISO picker
> *also in dark mode
> \*also in dark mode
> **Android only
> \*\*Android only
## Run the generator
- Android
- [iOS](screenshots/ios/README.md)
Screenshots will be stored in the _screenshots/generated/\<platform\>/_ folder.
### Android
```console
sh screenshots/generate_screenshots.sh <deviceName>
```
### iOS
Apple requires screenshots a specific list of devices, so we can implement a custom generator to cover all those devices.
Can be run on Simulator.
```console
sh screenshots/generate_ios_screenshots.sh
```
## List of devices
### Android
- Pixel 6
### iOS
- iPhone 8 Plus
- iPhone 13 Pro
- iPhone 13 Pro Max
- iPhone 15 Pro
- iPhone 15 Pro Max
- iPad Pro (12.9-inch) (6th generation)

View file

@ -1,22 +0,0 @@
# Generate iOS screenshots
## Context
The command below will generate screenshots for all the screen sizes required by App Store using iOS Simulator.
## Run the generator
```console
sh screenshots/ios/generate_screenshots.sh
```
Screenshots will be stored in the _screenshots/ios/generated/_ folder.
## List of devices
- iPhone 8 Plus
- iPhone 13 Pro
- iPhone 13 Pro Max
- iPhone 15 Pro
- iPhone 15 Pro Max
- iPad Pro (12.9-inch) (6th generation)

View file

@ -7,7 +7,7 @@ Future<void> main() async {
await grantCameraPermission();
await integrationDriver(
onScreenshot: (name, bytes, [args]) async {
final File image = await File('screenshots/$name.png').create(recursive: true);
final File image = await File('screenshots/generated/$name.png').create(recursive: true);
image.writeAsBytesSync(bytes);
return true;
},