Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Next Next commit
Skip verifying sample file on macOS
  • Loading branch information
vashworth committed Jun 5, 2024
commit 9b2096ca83f36947ff0dcd2db2c28f600b3346ff
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,15 @@ void main() {

testWidgets('getApplicationDocumentsDirectory', (WidgetTester tester) async {
final Directory result = await getApplicationDocumentsDirectory();
_verifySampleFile(result, 'applicationDocuments');
if (Platform.isMacOS) {
// _verifySampleFile causes hangs in driver when sandboxing is disabled
// because the path changes from an app specific directory to
// ~/Documents, which requires additional permissions to access on macOS.
// Instead, validate that a non-empty path was returned.
expect(result, isNotEmpty);
} else {
_verifySampleFile(result, 'applicationDocuments');
}
});

testWidgets('getApplicationSupportDirectory', (WidgetTester tester) async {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,15 @@ void main() {
testWidgets('getApplicationDocumentsDirectory', (WidgetTester tester) async {
final PathProviderPlatform provider = PathProviderPlatform.instance;
final String? result = await provider.getApplicationDocumentsPath();
_verifySampleFile(result, 'applicationDocuments');
if (Platform.isMacOS) {
// _verifySampleFile causes hangs in driver when sandboxing is disabled
// because the path changes from an app specific directory to
// ~/Documents, which requires additional permissions to access on macOS.
// Instead, validate that a non-empty path was returned.
expect(result, isNotEmpty);
} else {
_verifySampleFile(result, 'applicationDocuments');
}
});

testWidgets('getApplicationSupportDirectory', (WidgetTester tester) async {
Expand Down