mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
[flutter_tools] fix web messaging (#74513)
This commit is contained in:
parent
1d3f697160
commit
e599cdd414
@ -184,14 +184,7 @@ abstract class ResidentWebRunner extends ResidentRunner {
|
||||
fire + globals.terminal.bolden(rawMessage),
|
||||
TerminalColor.red,
|
||||
);
|
||||
if (!flutterNext) {
|
||||
globals.printStatus(
|
||||
"Warning: Flutter's support for web development is not stable yet and hasn't");
|
||||
globals.printStatus('been thoroughly tested in production environments.');
|
||||
globals.printStatus('For more information see https://flutter.dev/web');
|
||||
globals.printStatus('');
|
||||
globals.printStatus(message);
|
||||
}
|
||||
globals.printStatus(message);
|
||||
const String quitMessage = 'To quit, press "q".';
|
||||
if (device.device is! WebServerDevice) {
|
||||
globals.printStatus('For a more detailed help message, press "h". $quitMessage');
|
||||
|
||||
@ -891,6 +891,19 @@ void main() {
|
||||
Platform: () => FakePlatform(operatingSystem: 'linux', environment: <String, String>{}),
|
||||
});
|
||||
|
||||
testUsingContext('printHelp without details shows hot restart help message', () async {
|
||||
final ResidentRunner residentWebRunner = setUpResidentRunner(mockFlutterDevice);
|
||||
fakeVmServiceHost = FakeVmServiceHost(requests: <VmServiceExpectation>[]);
|
||||
residentWebRunner.printHelp(details: false);
|
||||
|
||||
expect(testLogger.statusText, contains('To hot restart changes'));
|
||||
}, overrides: <Type, Generator>{
|
||||
FileSystem: () => fileSystem,
|
||||
ProcessManager: () => processManager,
|
||||
Pub: () => MockPub(),
|
||||
Platform: () => FakePlatform(operatingSystem: 'linux', environment: <String, String>{}),
|
||||
});
|
||||
|
||||
testUsingContext('debugDumpApp', () async {
|
||||
final ResidentRunner residentWebRunner = setUpResidentRunner(mockFlutterDevice);
|
||||
fakeVmServiceHost = FakeVmServiceHost(requests: <VmServiceExpectation>[
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user