-
Notifications
You must be signed in to change notification settings - Fork 27.2k
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
[flutter_tools] even more test fixes #60156
[flutter_tools] even more test fixes #60156
Conversation
@@ -25,6 +26,8 @@ void main() { | |||
final List<Device> devices = <Device>[device1, device2, device3]; | |||
final DeviceManager deviceManager = TestDeviceManager(devices); | |||
expect(await deviceManager.getDevices(), devices); | |||
}, overrides: <Type, Generator>{ | |||
Artifacts: () => Artifacts.test(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hitting real artifacts, failing if they did not exist
@@ -791,28 +792,36 @@ void main() { | |||
}); | |||
|
|||
testUsingContext('Correct flutter runner', () async { | |||
expect(globals.artifacts.getArtifactPath( | |||
final MockCache cache = MockCache(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hitting real cache, failing if it didn't exist.
}); | ||
|
||
testUsingContext('Does not hot restart when device does not support it', () async { | ||
fileSystem.file(globalPackagesPath) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hitting real file system, failing if a .packages didn't exist
@@ -52,7 +51,6 @@ void main() { | |||
|
|||
String podsIsInCustomDir({String cocoapodsReposDir}) { | |||
cocoapodsReposDir ??= fileSystem.path.join( | |||
globals.fsUtils.homeDirPath, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test apparently doesn't rely on this value, avoid looking up potentially null home dir path
@@ -43,7 +43,9 @@ void main() { | |||
MockHttpServer mockHttpServer; | |||
|
|||
setUpAll(() async { | |||
packages = await loadPackageConfigUri(Uri.base.resolve('.packages')); | |||
packages = PackageConfig(<Package>[ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fails if .packages doesn't exist
Fix tests broken under tester
Description
Fix tests broken under tester