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 1
1
abstract class TestCommandBase {
2
2
public allowedParameters : ICommandParameter [ ] = [ ] ;
3
+ public dashedOptions = {
4
+ hmr : { type : OptionType . Boolean , default : false , hasSensitiveValue : false } ,
5
+ } ;
6
+
3
7
protected abstract platform : string ;
4
8
protected abstract $projectData : IProjectData ;
5
9
protected abstract $testExecutionService : ITestExecutionService ;
@@ -50,6 +54,13 @@ abstract class TestCommandBase {
50
54
51
55
async canExecute ( args : string [ ] ) : Promise < boolean | ICanExecuteCommandOutput > {
52
56
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
+
53
64
await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir , platforms : [ this . platform ] } ) ;
54
65
}
55
66
You can’t perform that action at this time.
0 commit comments