Skip to content
Open
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
2 changes: 1 addition & 1 deletion lib/resources/test_spec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ phases:

# install flutter
- echo "Install flutter"
- FLUTTER_VERSION='v1.12.13+hotfix.8-stable'
- echo "FLUTTER_VERSION=$FLUTTER_VERSION"
- >-
if [ $DEVICEFARM_DEVICE_PLATFORM_NAME = "Android" ];
then
Expand Down
7 changes: 6 additions & 1 deletion lib/src/resources.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ import 'package:tool_base/tool_base.dart';
const kResourcesUri = 'package:sylph/resources';
const kAppiumTemplateZip = 'appium_bundle.zip';
const kAppiumTestSpecName = 'test_spec.yaml';
const kdefaultFlutterVersion = '1.17.1-stable';
const kTestBundleDir = 'test_bundle';
const kTestBundleZip = '$kTestBundleDir.zip';
const kBuildToOsMapFileName = 'build_to_os.txt';

// env vars
const kCIEnvVar = 'CI'; // detects if running in CI
const kFlutterVersionEnvVar = 'FLUTTER_VERSION';
const kExportOptionsPlistEnvVars = [
// required for iOS build locally and in CI
'TEAM_ID'
Expand Down Expand Up @@ -43,7 +45,10 @@ Future<void> unpackResources(String tmpDir, bool isIosPoolTypeActive,
'$tmpDir/$kAppiumTemplateZip');

// unpack Appium test spec
await unpackFile(kAppiumTestSpecName, tmpDir);
await unpackFile(kAppiumTestSpecName, tmpDir, nameVals: {
kFlutterVersionEnvVar:
platform.environment[kFlutterVersionEnvVar] ?? kdefaultFlutterVersion
});

// unpack scripts
await unpackScripts(tmpDir);
Expand Down