File tree Expand file tree Collapse file tree 5 files changed +7
-5
lines changed Expand file tree Collapse file tree 5 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,7 @@ require('dotenv').config()
29
29
30
30
const commands = [
31
31
'--publish' ,
32
+ '--release' ,
32
33
'--fix-publish' ,
33
34
'--post-publish' ,
34
35
'--bump' ,
@@ -56,7 +57,7 @@ if (process.argv.includes('--help')) {
56
57
require ( './post-publish' )
57
58
} else if ( process . argv . includes ( '--bump' ) ) {
58
59
require ( './bump' )
59
- } else if ( process . argv . includes ( '--publish' ) ) {
60
+ } else if ( process . argv . includes ( '--publish' ) || process . argv . includes ( '--release' ) ) {
60
61
require ( './publish' )
61
62
} else if ( process . argv . includes ( '--fix-publish' ) ) {
62
63
require ( './fix-publish' )
@@ -87,4 +88,5 @@ if (process.argv.includes('--help')) {
87
88
} else {
88
89
error ( '[ui-scripts]: Invalid command!' )
89
90
listCommands ( )
91
+ process . exit ( 1 )
90
92
}
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ let args = [
32
32
'--colors' ,
33
33
'--require' , '@babel/register' ,
34
34
'--require' , '@babel/polyfill' ,
35
+ '--require' , 'jsdom-global/register' ,
35
36
'--exit'
36
37
]
37
38
Original file line number Diff line number Diff line change 35
35
"gh-pages" : " ^2.0.1" ,
36
36
"http-server" : " ^0.11.1" ,
37
37
"jira-client" : " ^6.6.0" ,
38
+ "jsdom-global" : " ^3.0.2" ,
38
39
"karma-cli" : " ^2.0.0" ,
39
40
"lerna" : " ^3" ,
40
41
"mocha" : " ^6.0.2" ,
47
48
"webpack-dev-server" : " ^3.2.1"
48
49
},
49
50
"peerDependencies" : {
51
+ "jsdom" : " >=10.0.0" ,
50
52
"react" : " ^0.14.9 || ^15 || ^16" ,
51
53
"webpack" : " ^4"
52
54
},
Original file line number Diff line number Diff line change 33
33
"chai-string" : " ^1.5.0" ,
34
34
"dirty-chai" : " ^2.0.1" ,
35
35
"fetch-mock" : " ^7.3.0" ,
36
- "jsdom-global" : " ^3.0.2" ,
37
36
"keycode" : " ^2" ,
38
37
"pretty-format" : " ^24.0.0" ,
39
38
"sinon" : " ^7.2.3" ,
42
41
"wait-for-expect" : " ^1.1.0"
43
42
},
44
43
"peerDependencies" : {
45
- "jsdom" : " >=10.0.0" ,
46
44
"react" : " ^0.14.9 || ^15.0.0 || ^16.0.0" ,
47
45
"react-dom" : " ^0.14.9 || ^15.0.0 || ^16.0.0"
48
46
},
Original file line number Diff line number Diff line change 21
21
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
* SOFTWARE.
23
23
*/
24
- import jsdom from 'jsdom-global'
25
24
import MutationObserverShim from '@sheerun/mutationobserver-shim'
26
25
27
26
const noop = ( ) => { }
@@ -30,7 +29,7 @@ let cleanupGlobals = noop
30
29
31
30
const initGlobals = ( ) => {
32
31
if ( typeof document === 'undefined' ) {
33
- cleanupGlobals = jsdom ( )
32
+ console . error ( `[ui-test-utils] requires access to the DOM API!` )
34
33
}
35
34
// jsdom doesn't provide Date on the window object and we need it for wait-for-expect
36
35
global . window . Date = ( global . window . Date && global . window . Date . now ) ? global . window . Date : global . Date
You can’t perform that action at this time.
0 commit comments