void printNumber() {
var number = 0;
print('The number is $number');
}
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
#import <Foundation/Foundation.h> | |
@interface PatrolIntegrationTestRunner : NSObject | |
+ (NSString *)createMethodNameFromPatrolGeneratedGroup:(NSString *)dartTestGroup; | |
@end | |
@implementation PatrolIntegrationTestRunner | |
- (instancetype)init { | |
self = [super init]; |
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
fun DartTestGroup.listFlatDartFiles(): List<String> { | |
val files = mutableListOf<String>() | |
for (group in groupsList) { | |
files.addAll(group.listGroups()) | |
} | |
return files.filter { it.endsWith(".dart") } | |
} | |
// Recursively lists groups in this group. | |
private fun DartTestGroup.listGroups(): List<String> { |
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
# display in protoc "text format" without keys | |
protoc --decode_raw < test-result.pb |
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
patrolTest( | |
'never settles when an invisible child of IndexedStack is requesting frames', | |
($) async { | |
await expectLater( | |
() async => $.pumpWidgetAndSettle( | |
MaterialApp( | |
home: Scaffold( | |
body: IndexedStack( | |
children: const [ | |
Center(child: Text('first child')), |
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
import XCTest | |
final class LandmarksUITests: XCTestCase { | |
let app = XCUIApplication() | |
override func setUpWithError() throws { | |
continueAfterFailure = false | |
app.launch() | |
} |
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
PlayStore.enabled=true | |
abi.type=x86_64 | |
avd.ini.displayname=Pixel 3 API 30 | |
avd.ini.encoding=UTF-8 | |
disk.dataPartition.size = 6442450944 | |
fastboot.chosenSnapshotFile= | |
fastboot.forceChosenSnapshotBoot=no | |
fastboot.forceColdBoot=no | |
fastboot.forceFastBoot=yes | |
hw.accelerometer=yes |
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
extension BuildContextLocalizations on BuildContext { | |
Locale get locale => Localizations.localeOf(this); | |
String get languageCode => locale.toLanguageTag(); | |
AppLocalizations get l10n => AppLocalizations.of(this)!; | |
List<Locale> get supportedLocales => AppLocalizations.supportedLocales; | |
List<Locale> get realSupportedLocales => AppLocalizationsX.supportedLocales; |
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
func getNativeWidgets() throws { | |
for i in 0...10 { | |
let toggle = self.springboard.switches.element(boundBy: i) | |
let label = toggle.label as String | |
let accLabel = toggle.accessibilityLabel as String? | |
let ident = toggle.identifier | |
Logger.shared.i("index: \(i), label: \(label), accLabel: \(String(describing: accLabel)), ident: \(ident)") | |
} | |
} |
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
#!/usr/bin/env bash | |
set -euo pipefail | |
# upload_artifact uploads a file to Azure Storage. | |
# | |
# Usage: | |
# | |
# AZURE_SAS_TOKEN=SOME_TOKEN ./upload_artifact your_file.txt | |
artifact="${1:-}" |