Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
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
Prev Previous commit
Add test for the moved code
  • Loading branch information
jtmcdole committed Oct 7, 2019
commit f0b64947fae96a1684a0f5a0a5b7458fb3858b51
15 changes: 14 additions & 1 deletion packages/video_player/test/video_player_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,20 @@ void main() {
expect(
fakeVideoPlayerPlatform.dataSourceDescriptions[0], <String, dynamic>{
'uri': 'https://127.0.0.1',
'formatHint': null,
});
});

test('initialize network with hint', () async {
final VideoPlayerController controller = VideoPlayerController.network(
'https://127.0.0.1',
formatHint: VideoFormat.dash);
await controller.initialize();

expect(
fakeVideoPlayerPlatform.dataSourceDescriptions[0], <String, dynamic>{
'uri': 'https://127.0.0.1',
'formatHint': 'dash',
});
});

Expand All @@ -123,7 +137,6 @@ void main() {
expect(
fakeVideoPlayerPlatform.dataSourceDescriptions[0], <String, dynamic>{
'uri': 'file://a.avi',
'formatHint': null,
});
});
});
Expand Down