2017-02-14 4 views

Antwort

0

Sieht aus wie in [email protected] kann es auf diese Weise geschehen:

/path/to/reporter-setup.js

function getTestPath() { 
    if (Symbol && typeof Symbol.for === 'function') { 
    var globalStateKey = Symbol.for('$$jest-matchers-object'); 
    if (globalStateKey) { 
     var globalState = global[globalStateKey]; 
     if (globalState) { 
     var state = globalState.state; 
     if (state) { 
      return state.testPath; 
     } 
     } 
    } 
    } 
} 

Scherz --setupTestFrameworkScriptFile/path/to/reporter-setup.js

Verwandte Themen