-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
31 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Screenshots |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,28 @@ | ||
#!/bin/sh | ||
|
||
mkdir -p Screenshots | ||
|
||
# TODO: `xcrun simctl create $target $target` if missing. | ||
if [ "$#" -eq 0 ] | ||
then | ||
targets=('iPhone 14 Plus' 'iPhone 8 Plus' 'iPad Pro (12.9-inch) (6th generation)' 'iPad Pro (12.9-inch) (2nd generation)') | ||
targets=('iPhone 14 Plus' 'iPhone 8 Plus' 'iPad Pro (12.9-inch) (6th generation)' 'iPad Pro (12.9-inch) (2nd generation)', 'macOS') | ||
else | ||
targets=("${@}") | ||
fi | ||
|
||
time='2021-03-14T11:23:58-04:00' | ||
for target in "${targets[@]}" | ||
do | ||
xcrun simctl bootstatus "$target" -b | ||
xcrun simctl status_bar "$target" override --time $time --batteryState charged --batteryLevel 100 --operatorName idk --cellularBars 4 --dataNetwork 'hide' | ||
xcrun simctl ui "$target" appearance dark | ||
xcrun simctl io "$target" recordVideo --codec=h264 "$target.mp4" & | ||
RECORD_PID=$! | ||
xcparse screenshots --model `sh -c "xcodebuild test -parallel-testing-enabled NO -target MarkologyUITests -scheme Markology -destination 'name=$target'" | grep xcresult` . | ||
kill -INT $RECORD_PID | ||
if [ 'macOS' = "$target" ] | ||
then | ||
xcparse screenshots --model `sh -c "xcodebuild test -parallel-testing-enabled NO -scheme MarkologyUITests -destination 'platform=macOS'" | grep xcresult` Screenshots | ||
else | ||
xcrun simctl bootstatus "$target" -b | ||
xcrun simctl status_bar "$target" override --time $time --batteryState charged --batteryLevel 100 --operatorName idk --cellularBars 4 --dataNetwork 'hide' | ||
xcrun simctl ui "$target" appearance dark | ||
xcrun simctl io "$target" recordVideo --codec=h264 "Screenshots/$target.mp4" & | ||
RECORD_PID=$! | ||
xcparse screenshots --model `sh -c "xcodebuild test -parallel-testing-enabled NO -scheme MarkologyUITests -destination 'name=$target'" | grep xcresult` Screenshots | ||
kill -INT $RECORD_PID | ||
fi | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.