Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: adding gradlew version to the doctor output #2255

Merged
merged 10 commits into from
Jun 18, 2024
34 changes: 28 additions & 6 deletions packages/shorebird_cli/test/src/executables/gradlew_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -343,12 +343,34 @@ Make sure you have run "flutter build apk" at least once.''',
});

group('when gradlew exists', () {
test('returns true', () {
File(
p.join(tempDir.path, 'android', 'gradlew'),
).createSync(recursive: true);
expect(gradlew.exists(tempDir.path), isTrue);
});
group(
'when on mac and linux',
() {
test('returns true', () {
File(
p.join(tempDir.path, 'android', 'gradlew'),
).createSync(recursive: true);
erickzanardo marked this conversation as resolved.
Show resolved Hide resolved
expect(gradlew.exists(tempDir.path), isTrue);
});
},
onPlatform: {'windows': const Skip()},
);

group(
'when on windows',
() {
test('returns true', () {
File(
p.join(tempDir.path, 'android', 'gradlew.bat'),
).createSync(recursive: true);
erickzanardo marked this conversation as resolved.
Show resolved Hide resolved
expect(gradlew.exists(tempDir.path), isTrue);
});
},
onPlatform: {
'mac-os': const Skip(),
'linux': const Skip(),
},
);
});
});

Expand Down
Loading