File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 11abstract class TestCommandBase {
22 public allowedParameters : ICommandParameter [ ] = [ ] ;
3+ public dashedOptions = {
4+ hmr : { type : OptionType . Boolean , default : false , hasSensitiveValue : false } ,
5+ } ;
6+
37 protected abstract platform : string ;
48 protected abstract $projectData : IProjectData ;
59 protected abstract $testExecutionService : ITestExecutionService ;
@@ -50,6 +54,13 @@ abstract class TestCommandBase {
5054
5155 async canExecute ( args : string [ ] ) : Promise < boolean | ICanExecuteCommandOutput > {
5256 if ( ! this . $options . force ) {
57+ if ( this . $options . hmr ) {
58+ // With HMR we are not restarting after LiveSync which is causing a 30 seconds app start on Android
59+ // because the Runtime does not watch for the `/data/local/tmp<appId>-livesync-in-progress` file deletion.
60+ // The App is closing itself after each test execution and the bug will be reproducible on each LiveSync.
61+ this . $errors . fail ( "The `--hmr` option is not supported for this command." ) ;
62+ }
63+
5364 await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir , platforms : [ this . platform ] } ) ;
5465 }
5566
You can’t perform that action at this time.
0 commit comments