This repository was archived by the owner on Apr 12, 2024. It is now read-only.
File tree 1 file changed +19
-23
lines changed
1 file changed +19
-23
lines changed Original file line number Diff line number Diff line change @@ -46,32 +46,28 @@ function generateFixture(test, query) {
46
46
}
47
47
} ) ;
48
48
49
- if ( jquery && ( ! ( 'jquery' in query ) || ( / ^ ( 0 | n o | f a l s e | o f f | n ) $ / i) . test ( query . jquery ) ) ) {
50
- $ ( jquery ) . remove ( ) ;
51
- } else if ( 'jquery' in query ) {
52
- if ( ( / ^ ( 0 | n o | f a l s e | o f f | n ) $ / i) . test ( query . jquery ) ) {
53
- if ( jquery ) {
54
- $ ( jquery ) . remove ( ) ;
55
- }
56
- } else {
57
- if ( ! jquery ) {
58
- jquery = $ . load ( '<script></script>' ) ( 'script' ) [ 0 ] ;
59
- if ( firstScript ) {
60
- $ ( firstScript ) . before ( jquery ) ;
49
+ if ( ! ( 'jquery' in query ) || ( / ^ ( 0 | n o | f a l s e | o f f | n ) $ / i) . test ( query . jquery ) ) {
50
+ if ( jquery ) {
51
+ $ ( jquery ) . remove ( ) ;
52
+ }
53
+ } else {
54
+ if ( ! jquery ) {
55
+ jquery = $ . load ( '<script></script>' ) ( 'script' ) [ 0 ] ;
56
+ if ( firstScript ) {
57
+ $ ( firstScript ) . before ( jquery ) ;
58
+ } else {
59
+ var head = $$ ( 'head' ) ;
60
+ if ( head . length ) {
61
+ head . prepend ( jquery ) ;
61
62
} else {
62
- var head = $$ ( 'head' ) ;
63
- if ( head . length ) {
64
- head . prepend ( jquery ) ;
65
- } else {
66
- $$ . root ( ) . first ( ) . before ( jquery ) ;
67
- }
63
+ $$ . root ( ) . first ( ) . before ( jquery ) ;
68
64
}
69
65
}
70
- if ( ! / ^ \d + \. \d + . * $ / . test ( query . jquery ) ) {
71
- $ ( jquery ) . attr ( 'src' , '/bower_components/jquery/dist/jquery.js' ) ;
72
- } else {
73
- $ ( jquery ) . attr ( 'src' , '//ajax.googleapis.com/ajax/libs/jquery/' + query . jquery + '/jquery.js' ) ;
74
- }
66
+ }
67
+ if ( ! / ^ \d + \. \d + . * $ / . test ( query . jquery ) ) {
68
+ $ ( jquery ) . attr ( 'src' , '/bower_components/jquery/dist/jquery.js' ) ;
69
+ } else {
70
+ $ ( jquery ) . attr ( 'src' , '//ajax.googleapis.com/ajax/libs/jquery/' + query . jquery + '/jquery.js' ) ;
75
71
}
76
72
}
77
73
You can’t perform that action at this time.
0 commit comments