auth0-lock 11.34.2 → 12.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (241) hide show
  1. package/.browserslistrc +1 -0
  2. package/.circleci/config.yml +4 -2
  3. package/.eslintrc.json +5 -5
  4. package/.github/workflows/codeql.yml +41 -0
  5. package/.shiprc +4 -5
  6. package/CHANGELOG.md +26 -0
  7. package/EXAMPLES.md +626 -0
  8. package/README.md +77 -649
  9. package/karma.conf.js +1 -1
  10. package/lib/CSSCore.js +1 -4
  11. package/lib/__tests__/auth_button.js +12 -22
  12. package/lib/__tests__/connection/database/actions.js +48 -49
  13. package/lib/__tests__/connection/database/index.js +22 -28
  14. package/lib/__tests__/connection/database/login_pane.js +20 -41
  15. package/lib/__tests__/connection/database/password_reset_confirmation.js +19 -26
  16. package/lib/__tests__/connection/database/reset_password.js +17 -39
  17. package/lib/__tests__/connection/database/signed_up_confirmation.js +19 -26
  18. package/lib/__tests__/connection/enterprise/actions.js +22 -47
  19. package/lib/__tests__/connection/enterprise/hrd_pane.js +16 -33
  20. package/lib/__tests__/connection/enterprise/hrd_screen.js +26 -40
  21. package/lib/__tests__/connection/enterprise/quick_auth_screen.js +27 -68
  22. package/lib/__tests__/connection/passwordless/ask_vcode.js +29 -51
  23. package/lib/__tests__/connection/passwordless/email_sent_confirmation.js +19 -26
  24. package/lib/__tests__/connection/passwordless/passwordless.js +35 -97
  25. package/lib/__tests__/core/actions.js +23 -46
  26. package/lib/__tests__/core/client/index.js +10 -13
  27. package/lib/__tests__/core/index.js +46 -94
  28. package/lib/__tests__/core/remote_data.js +14 -20
  29. package/lib/__tests__/core/signed_in_confirmation.js +19 -26
  30. package/lib/__tests__/core/sso/last_login_screen.js +27 -50
  31. package/lib/__tests__/core/tenant.js +10 -12
  32. package/lib/__tests__/core/web_api/helper.js +6 -14
  33. package/lib/__tests__/core/web_api/p2_api.js +38 -33
  34. package/lib/__tests__/core/web_api.js +37 -33
  35. package/lib/__tests__/engine/classic/login.js +20 -41
  36. package/lib/__tests__/engine/classic/mfa_login_screen.js +6 -19
  37. package/lib/__tests__/engine/classic/sign_up_pane.js +33 -55
  38. package/lib/__tests__/engine/classic/sign_up_screen.js +18 -45
  39. package/lib/__tests__/engine/classic.js +13 -6
  40. package/lib/__tests__/engine/passwordless.js +2 -5
  41. package/lib/__tests__/field/captcha/recaptcha_enterprise.js +27 -27
  42. package/lib/__tests__/field/captcha/recaptchav2.js +27 -27
  43. package/lib/__tests__/field/captcha.js +39 -51
  44. package/lib/__tests__/field/custom_input.js +23 -47
  45. package/lib/__tests__/field/email.js +2 -3
  46. package/lib/__tests__/field/email_pane.js +25 -48
  47. package/lib/__tests__/field/field.js +9 -13
  48. package/lib/__tests__/field/login_pane.js +30 -34
  49. package/lib/__tests__/field/mfa_code_pane.js +13 -28
  50. package/lib/__tests__/field/option_selection_pane.js +7 -25
  51. package/lib/__tests__/field/password.js +6 -12
  52. package/lib/__tests__/field/password_pane.js +29 -46
  53. package/lib/__tests__/field/phone_number_pane.js +18 -41
  54. package/lib/__tests__/field/social_buttons_pane.js +30 -47
  55. package/lib/__tests__/field/username.js +27 -48
  56. package/lib/__tests__/field/username_pane.js +30 -47
  57. package/lib/__tests__/field/vcode.js +5 -13
  58. package/lib/__tests__/field/vcode_pane.js +20 -44
  59. package/lib/__tests__/i18n.js +28 -53
  60. package/lib/__tests__/quick-auth/actions.js +4 -27
  61. package/lib/__tests__/setup-tests.js +7 -9
  62. package/lib/__tests__/testUtils.js +41 -58
  63. package/lib/__tests__/ui/box/chrome.js +24 -49
  64. package/lib/__tests__/ui/box/confirmation_pane.js +19 -36
  65. package/lib/__tests__/ui/box/container.js +21 -46
  66. package/lib/__tests__/ui/box/global_message.js +60 -37
  67. package/lib/__tests__/ui/input/email_input.js +6 -17
  68. package/lib/__tests__/ui/input/input_wrap.js +6 -19
  69. package/lib/__tests__/ui/input/password/password_strength.js +13 -15
  70. package/lib/__tests__/ui/input/password_input.js +22 -27
  71. package/lib/__tests__/utils/format.js +10 -17
  72. package/lib/__tests__/utils/url_utils.js +2 -5
  73. package/lib/avatar/gravatar_provider.js +13 -28
  74. package/lib/avatar.js +22 -41
  75. package/lib/browser.js +372 -23
  76. package/lib/connection/captcha.js +14 -32
  77. package/lib/connection/database/actions.js +39 -108
  78. package/lib/connection/database/index.js +90 -191
  79. package/lib/connection/database/login_pane.js +107 -147
  80. package/lib/connection/database/login_sign_up_tabs.js +106 -125
  81. package/lib/connection/database/mfa_pane.js +50 -69
  82. package/lib/connection/database/password_reset_confirmation.js +51 -73
  83. package/lib/connection/database/reset_password.js +116 -132
  84. package/lib/connection/database/reset_password_pane.js +45 -56
  85. package/lib/connection/database/sign_up_terms.js +17 -23
  86. package/lib/connection/database/signed_up_confirmation.js +52 -75
  87. package/lib/connection/enterprise/actions.js +23 -52
  88. package/lib/connection/enterprise/hrd_pane.js +60 -76
  89. package/lib/connection/enterprise/hrd_screen.js +60 -75
  90. package/lib/connection/enterprise/kerberos_screen.js +46 -60
  91. package/lib/connection/enterprise/quick_auth_screen.js +46 -64
  92. package/lib/connection/enterprise/single_sign_on_notice.js +14 -26
  93. package/lib/connection/enterprise.js +51 -84
  94. package/lib/connection/passwordless/actions.js +29 -62
  95. package/lib/connection/passwordless/ask_vcode.js +53 -60
  96. package/lib/connection/passwordless/email_sent_confirmation.js +129 -179
  97. package/lib/connection/passwordless/index.js +36 -68
  98. package/lib/connection/social/index.js +12 -15
  99. package/lib/core/actions.js +33 -85
  100. package/lib/core/client/index.js +38 -58
  101. package/lib/core/client/settings.js +12 -20
  102. package/lib/core/error_screen.js +38 -52
  103. package/lib/core/index.js +152 -301
  104. package/lib/core/loading_screen.js +61 -71
  105. package/lib/core/pane_separator.js +10 -10
  106. package/lib/core/remote_data.js +28 -48
  107. package/lib/core/screen.js +85 -79
  108. package/lib/core/signed_in_confirmation.js +51 -73
  109. package/lib/core/sso/data.js +9 -17
  110. package/lib/core/sso/index.js +5 -6
  111. package/lib/core/sso/last_login_screen.js +46 -63
  112. package/lib/core/tenant/index.js +37 -59
  113. package/lib/core/tenant/settings.js +11 -15
  114. package/lib/core/web_api/helper.js +24 -30
  115. package/lib/core/web_api/p2_api.js +156 -165
  116. package/lib/core/web_api.js +101 -90
  117. package/lib/core.js +126 -160
  118. package/lib/engine/classic/login.js +92 -144
  119. package/lib/engine/classic/mfa_login_screen.js +61 -67
  120. package/lib/engine/classic/sign_up_pane.js +89 -123
  121. package/lib/engine/classic/sign_up_screen.js +112 -158
  122. package/lib/engine/classic.js +122 -183
  123. package/lib/engine/passwordless/social_or_email_login_screen.js +71 -106
  124. package/lib/engine/passwordless/social_or_phone_number_login_screen.js +70 -100
  125. package/lib/engine/passwordless.js +75 -104
  126. package/lib/field/actions.js +11 -17
  127. package/lib/field/captcha/captcha_pane.js +82 -102
  128. package/lib/field/captcha/recaptcha.js +140 -145
  129. package/lib/field/captcha.js +7 -10
  130. package/lib/field/custom_input.js +37 -50
  131. package/lib/field/email/email_pane.js +90 -109
  132. package/lib/field/email.js +17 -35
  133. package/lib/field/index.js +51 -88
  134. package/lib/field/mfa-code/mfa_code_pane.js +57 -71
  135. package/lib/field/mfa_code.js +15 -21
  136. package/lib/field/option_selection_pane.js +16 -22
  137. package/lib/field/password/password_pane.js +79 -91
  138. package/lib/field/password.js +8 -14
  139. package/lib/field/phone-number/locations.js +7 -3
  140. package/lib/field/phone-number/phone_number_pane.js +87 -124
  141. package/lib/field/phone_number.js +16 -30
  142. package/lib/field/social/event.js +9 -12
  143. package/lib/field/social/social_buttons_pane.js +93 -121
  144. package/lib/field/username/username_pane.js +105 -123
  145. package/lib/field/username.js +16 -26
  146. package/lib/field/vcode/vcode_pane.js +67 -93
  147. package/lib/field/vcode.js +5 -5
  148. package/lib/i18n/af.js +7 -4
  149. package/lib/i18n/ar.js +7 -4
  150. package/lib/i18n/az.js +7 -4
  151. package/lib/i18n/bg.js +7 -4
  152. package/lib/i18n/ca.js +7 -4
  153. package/lib/i18n/cs.js +7 -4
  154. package/lib/i18n/da.js +7 -4
  155. package/lib/i18n/de.js +7 -3
  156. package/lib/i18n/el.js +7 -4
  157. package/lib/i18n/en.js +9 -4
  158. package/lib/i18n/es.js +7 -3
  159. package/lib/i18n/et.js +7 -4
  160. package/lib/i18n/fa.js +7 -4
  161. package/lib/i18n/fi.js +7 -4
  162. package/lib/i18n/fr.js +7 -4
  163. package/lib/i18n/he.js +7 -4
  164. package/lib/i18n/hr.js +7 -4
  165. package/lib/i18n/hu.js +7 -4
  166. package/lib/i18n/id.js +7 -4
  167. package/lib/i18n/it.js +7 -3
  168. package/lib/i18n/ja.js +7 -4
  169. package/lib/i18n/ko.js +7 -4
  170. package/lib/i18n/lt.js +7 -4
  171. package/lib/i18n/lv.js +7 -4
  172. package/lib/i18n/ms.js +7 -4
  173. package/lib/i18n/nb.js +7 -4
  174. package/lib/i18n/nl.js +7 -4
  175. package/lib/i18n/nn.js +7 -4
  176. package/lib/i18n/no.js +7 -4
  177. package/lib/i18n/pl.js +7 -4
  178. package/lib/i18n/pt-br.js +7 -3
  179. package/lib/i18n/pt.js +7 -4
  180. package/lib/i18n/ro.js +7 -4
  181. package/lib/i18n/ru.js +7 -4
  182. package/lib/i18n/sk.js +7 -4
  183. package/lib/i18n/sl.js +7 -4
  184. package/lib/i18n/sr.js +7 -4
  185. package/lib/i18n/sv.js +7 -4
  186. package/lib/i18n/tr.js +7 -4
  187. package/lib/i18n/ua.js +7 -4
  188. package/lib/i18n/uk.js +7 -4
  189. package/lib/i18n/vi.js +7 -4
  190. package/lib/i18n/zh-tw.js +7 -4
  191. package/lib/i18n/zh.js +7 -4
  192. package/lib/i18n.js +38 -75
  193. package/lib/index.js +14 -17
  194. package/lib/lock.js +29 -32
  195. package/lib/passwordless.js +29 -31
  196. package/lib/quick-auth/actions.js +19 -26
  197. package/lib/quick_auth.js +8 -10
  198. package/lib/sanitizer.js +5 -5
  199. package/lib/store/index.js +22 -42
  200. package/lib/sync.js +21 -42
  201. package/lib/ui/box/button.js +85 -105
  202. package/lib/ui/box/chrome.js +463 -548
  203. package/lib/ui/box/confirmation_pane.js +34 -48
  204. package/lib/ui/box/container.js +305 -339
  205. package/lib/ui/box/global_message.js +51 -60
  206. package/lib/ui/box/header.js +155 -177
  207. package/lib/ui/box/multisize_slide.js +233 -229
  208. package/lib/ui/box/success_pane.js +34 -37
  209. package/lib/ui/box.js +88 -93
  210. package/lib/ui/button/auth_button.js +44 -51
  211. package/lib/ui/input/captcha_input.js +162 -181
  212. package/lib/ui/input/checkbox_input.js +57 -59
  213. package/lib/ui/input/email_input.js +117 -124
  214. package/lib/ui/input/input_wrap.js +65 -80
  215. package/lib/ui/input/location_input.js +130 -150
  216. package/lib/ui/input/mfa_code_input.js +98 -98
  217. package/lib/ui/input/password/password_strength.js +103 -127
  218. package/lib/ui/input/password_input.js +141 -147
  219. package/lib/ui/input/phone_number_input.js +101 -109
  220. package/lib/ui/input/select_input.js +120 -132
  221. package/lib/ui/input/text_input.js +89 -84
  222. package/lib/ui/input/username_input.js +109 -115
  223. package/lib/ui/input/vcode_input.js +110 -118
  224. package/lib/ui/list.js +224 -247
  225. package/lib/ui/pane/quick_auth_pane.js +55 -80
  226. package/lib/utils/atom.js +55 -48
  227. package/lib/utils/cache.js +54 -43
  228. package/lib/utils/cdn_utils.js +17 -31
  229. package/lib/utils/createRef.js +3 -1
  230. package/lib/utils/data_utils.js +10 -16
  231. package/lib/utils/fn_utils.js +5 -4
  232. package/lib/utils/format.js +6 -8
  233. package/lib/utils/id_utils.js +4 -3
  234. package/lib/utils/jsonp_utils.js +20 -17
  235. package/lib/utils/media_utils.js +4 -2
  236. package/lib/utils/preload_utils.js +4 -3
  237. package/lib/utils/string_utils.js +4 -4
  238. package/lib/utils/url_utils.js +4 -3
  239. package/opslevel.yml +6 -0
  240. package/package.json +53 -38
  241. package/webpack.config.js +36 -3
@@ -1,47 +1,33 @@
1
- 'use strict';
2
-
3
- var _immutable = require('immutable');
4
-
5
- var _immutable2 = _interopRequireDefault(_immutable);
6
-
7
- var _data_utils = require('../../utils/data_utils');
8
-
9
- var _index = require('../../core/index');
10
-
11
- var _i18n = require('../../i18n');
12
-
13
- var _testUtils = require('../testUtils');
1
+ "use strict";
14
2
 
3
+ var _immutable = _interopRequireDefault(require("immutable"));
4
+ var _data_utils = require("../../utils/data_utils");
5
+ var _index = require("../../core/index");
6
+ var _i18n = require("../../i18n");
7
+ var _testUtils = require("../testUtils");
15
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
16
-
17
9
  var setResolvedConnection = function setResolvedConnection() {
18
10
  var _require;
19
-
20
11
  return (_require = require('core/index')).setResolvedConnection.apply(_require, arguments);
21
12
  };
22
13
  var setup = function setup() {
23
14
  var _require2;
24
-
25
15
  return (_require2 = require('core/index')).setup.apply(_require2, arguments);
26
16
  };
27
-
28
17
  var mockLock = 'm';
29
- var mockSet = void 0;
30
- var mockInit = void 0;
31
-
18
+ var mockSet;
19
+ var mockInit;
32
20
  jest.mock('i18n', function () {
33
21
  return {
34
22
  initI18n: jest.fn(),
35
23
  html: function html() {
36
- for (var _len = arguments.length, keys = Array(_len), _key = 0; _key < _len; _key++) {
24
+ for (var _len = arguments.length, keys = new Array(_len), _key = 0; _key < _len; _key++) {
37
25
  keys[_key] = arguments[_key];
38
26
  }
39
-
40
27
  return keys.join();
41
28
  }
42
29
  };
43
30
  });
44
-
45
31
  jest.mock('utils/data_utils', function () {
46
32
  return {
47
33
  dataFns: function dataFns() {
@@ -53,37 +39,33 @@ jest.mock('utils/data_utils', function () {
53
39
  }
54
40
  };
55
41
  });
56
-
57
42
  describe('setup', function () {
58
43
  beforeEach(function () {
59
44
  mockInit = jest.fn();
60
45
  jest.resetModules();
61
46
  });
62
-
63
47
  it('default redirectUrl should not include location.hash', function () {
64
48
  (0, _testUtils.setURL)('https://test.com/path/#not-this-part');
65
49
  var options = {};
66
50
  setup('id', 'clientID', 'domain', options, 'hookRunner', 'emitEventFn');
67
51
  var _mockInit = mockInit,
68
- mock = _mockInit.mock;
69
-
52
+ mock = _mockInit.mock;
70
53
  expect(mock.calls.length).toBe(1);
71
54
  var model = mock.calls[0][1].toJS();
72
55
  expect(model.auth.redirectUrl).toBe('https://test.com/path/');
73
56
  });
74
-
75
- it('default redirectUrl should work when `window.location.origin` is not available', function () {
76
- (0, _testUtils.setURL)('https://test.com/path/#not-this-part', { noOrigin: true });
57
+ it.only('default redirectUrl should work when `window.location.origin` is not available', function () {
58
+ jsdom.reconfigure({
59
+ url: 'https://test.com/path/#not-this-part'
60
+ });
77
61
  var options = {};
78
62
  setup('id', 'clientID', 'domain', options, 'hookRunner', 'emitEventFn');
79
63
  var _mockInit2 = mockInit,
80
- mock = _mockInit2.mock;
81
-
64
+ mock = _mockInit2.mock;
82
65
  expect(mock.calls.length).toBe(1);
83
66
  var model = mock.calls[0][1].toJS();
84
67
  expect(model.auth.redirectUrl).toBe('https://test.com/path/');
85
68
  });
86
-
87
69
  it('should work with redirect:false and responseType:id_token', function () {
88
70
  var options = {
89
71
  auth: {
@@ -91,131 +73,91 @@ describe('setup', function () {
91
73
  responseType: 'id_token'
92
74
  }
93
75
  };
94
-
95
76
  setup('id', 'clientID', 'domain', options, 'hookRunner', 'emitEventFn', 'handleEventFn');
96
77
  var _mockInit3 = mockInit,
97
- mock = _mockInit3.mock;
98
-
78
+ mock = _mockInit3.mock;
99
79
  expect(mock.calls.length).toBe(1);
100
80
  var model = mock.calls[0][1].toJS();
101
81
  expect(model).toMatchSnapshot();
102
82
  });
103
-
104
83
  describe('clientBaseUrl', function () {
105
84
  it('should default to the specified domain', function () {
106
85
  var _mockInit4 = mockInit,
107
- mock = _mockInit4.mock;
108
-
109
-
86
+ mock = _mockInit4.mock;
110
87
  setup('id', 'clientID', 'my-tenant.us.auth0.com', {}, 'hookRunner', 'emitEventFn', 'handleEventFn');
111
-
112
88
  expect(mock.calls.length).toBe(1);
113
-
114
89
  var model = mock.calls[0][1].toJS();
115
90
  expect(model.clientBaseUrl).toBe('https://my-tenant.us.auth0.com');
116
91
  });
117
-
118
92
  it('should use the clientBaseUrl option if given', function () {
119
93
  var _mockInit5 = mockInit,
120
- mock = _mockInit5.mock;
121
-
122
-
94
+ mock = _mockInit5.mock;
123
95
  setup('id', 'clientID', 'my-tenant.us.auth0.com', {
124
96
  clientBaseUrl: 'https://client-base-url.example.com',
125
97
  configurationBaseUrl: 'https://config-base-url.example.com',
126
98
  assetsUrl: 'https://assets-url.example.com'
127
99
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
128
-
129
100
  expect(mock.calls.length).toBe(1);
130
-
131
101
  var model = mock.calls[0][1].toJS();
132
102
  expect(model.clientBaseUrl).toBe('https://client-base-url.example.com');
133
103
  });
134
-
135
104
  it('should use configurationBaseUrl if given', function () {
136
105
  var _mockInit6 = mockInit,
137
- mock = _mockInit6.mock;
138
-
139
-
106
+ mock = _mockInit6.mock;
140
107
  setup('id', 'clientID', 'my-tenant.us.auth0.com', {
141
108
  configurationBaseUrl: 'https://config-base-url.example.com',
142
109
  assetsUrl: 'https://assets-url.example.com'
143
110
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
144
-
145
111
  expect(mock.calls.length).toBe(1);
146
-
147
112
  var model = mock.calls[0][1].toJS();
148
113
  expect(model.clientBaseUrl).toBe('https://config-base-url.example.com');
149
114
  });
150
-
151
115
  it('should use assetsUrl if given', function () {
152
116
  var _mockInit7 = mockInit,
153
- mock = _mockInit7.mock;
154
-
155
-
117
+ mock = _mockInit7.mock;
156
118
  setup('id', 'clientID', 'my-tenant.us.auth0.com', {
157
119
  assetsUrl: 'https://assets-url.example.com'
158
120
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
159
-
160
121
  expect(mock.calls.length).toBe(1);
161
-
162
122
  var model = mock.calls[0][1].toJS();
163
123
  expect(model.clientBaseUrl).toBe('https://assets-url.example.com');
164
124
  });
165
125
  });
166
-
167
126
  describe('tenantBaseUrl', function () {
168
127
  it('should default to domain URL when using auth0.com', function () {
169
128
  var _mockInit8 = mockInit,
170
- mock = _mockInit8.mock;
171
-
172
-
129
+ mock = _mockInit8.mock;
173
130
  setup('id', 'clientID', 'my-tenant.us.auth0.com', {
174
131
  __useTenantInfo: true
175
132
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
176
-
177
133
  expect(mock.calls.length).toBe(1);
178
-
179
134
  var model = mock.calls[0][1].toJS();
180
135
  expect(model.tenantBaseUrl).toBe('https://my-tenant.us.auth0.com/tenants/v1/my-tenant.js');
181
136
  });
182
-
183
137
  it('should default to domain URL when using a custom domain', function () {
184
138
  var _mockInit9 = mockInit,
185
- mock = _mockInit9.mock;
186
-
187
-
139
+ mock = _mockInit9.mock;
188
140
  setup('id', 'clientID', 'auth.my-tenant.com', {
189
141
  __useTenantInfo: true
190
142
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
191
-
192
143
  expect(mock.calls.length).toBe(1);
193
-
194
144
  var model = mock.calls[0][1].toJS();
195
145
  expect(model.tenantBaseUrl).toBe('https://auth.my-tenant.com/info-v1.js');
196
146
  });
197
-
198
147
  it('should use configurationBaseUrl if specified', function () {
199
148
  var _mockInit10 = mockInit,
200
- mock = _mockInit10.mock;
201
-
202
-
149
+ mock = _mockInit10.mock;
203
150
  setup('id', 'clientID', 'auth.my-tenant.com', {
204
151
  __useTenantInfo: true,
205
152
  configurationBaseUrl: 'https://config-base-url.com'
206
153
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
207
-
208
154
  expect(mock.calls.length).toBe(1);
209
-
210
155
  var model = mock.calls[0][1].toJS();
211
156
  expect(model.tenantBaseUrl).toBe('https://config-base-url.com/info-v1.js');
212
157
  });
213
-
214
158
  it('should use configurationBaseUrl with a custom tenant if specified', function () {
215
159
  var _mockInit11 = mockInit,
216
- mock = _mockInit11.mock;
217
-
218
-
160
+ mock = _mockInit11.mock;
219
161
  setup('id', 'clientID', 'auth.my-tenant.com', {
220
162
  __useTenantInfo: true,
221
163
  configurationBaseUrl: 'https://config-base-url.com',
@@ -223,15 +165,12 @@ describe('setup', function () {
223
165
  __tenant: 'custom-tenant'
224
166
  }
225
167
  }, 'hookRunner', 'emitEventFn', 'handleEventFn');
226
-
227
168
  expect(mock.calls.length).toBe(1);
228
-
229
169
  var model = mock.calls[0][1].toJS();
230
170
  expect(model.tenantBaseUrl).toBe('https://config-base-url.com/tenants/v1/custom-tenant.js');
231
171
  });
232
172
  });
233
173
  });
234
-
235
174
  describe('setResolvedConnection', function () {
236
175
  beforeEach(function () {
237
176
  mockSet = jest.fn();
@@ -247,33 +186,46 @@ describe('setResolvedConnection', function () {
247
186
  return setResolvedConnection(mockLock, {});
248
187
  }).toThrowErrorMatchingSnapshot();
249
188
  expect(function () {
250
- return setResolvedConnection(mockLock, { type: 'foo' });
189
+ return setResolvedConnection(mockLock, {
190
+ type: 'foo'
191
+ });
251
192
  }).toThrowErrorMatchingSnapshot();
252
193
  expect(function () {
253
- return setResolvedConnection(mockLock, { name: 'bar' });
194
+ return setResolvedConnection(mockLock, {
195
+ name: 'bar'
196
+ });
254
197
  }).toThrowErrorMatchingSnapshot();
255
198
  });
256
199
  it('accepts only database connections', function () {
257
200
  expect(function () {
258
- return setResolvedConnection(mockLock, { type: 'foo', name: 'bar' });
201
+ return setResolvedConnection(mockLock, {
202
+ type: 'foo',
203
+ name: 'bar'
204
+ });
259
205
  }).toThrowErrorMatchingSnapshot();
260
206
  });
261
207
  it('sets the connection', function () {
262
- setResolvedConnection(mockLock, { type: 'database', name: 'bar' });
208
+ setResolvedConnection(mockLock, {
209
+ type: 'database',
210
+ name: 'bar'
211
+ });
263
212
  expect(mockSet.mock.calls.length).toBe(1);
264
213
  expect(mockSet.mock.calls[0]).toMatchSnapshot();
265
214
  });
266
215
  it('sets the connection as a Map instance', function () {
267
- setResolvedConnection(mockLock, { type: 'database', name: 'bar' });
216
+ setResolvedConnection(mockLock, {
217
+ type: 'database',
218
+ name: 'bar'
219
+ });
268
220
  expect(mockSet.mock.calls.length).toBe(1);
269
- expect(_immutable2.default.Map.isMap(mockSet.mock.calls[0][2])).toBe(true);
221
+ expect(_immutable.default.Map.isMap(mockSet.mock.calls[0][2])).toBe(true);
270
222
  });
271
223
  });
272
-
273
224
  describe('loginErrorMessage', function () {
274
225
  it('maps `password_expired` to `password_change_required`', function () {
275
- var result = (0, _index.loginErrorMessage)(mockLock, { code: 'password_expired' }, 'type');
276
-
226
+ var result = (0, _index.loginErrorMessage)(mockLock, {
227
+ code: 'password_expired'
228
+ }, 'type');
277
229
  expect(result).toBe([mockLock, 'error', 'login', 'password_change_required'].join());
278
230
  });
279
231
  });
@@ -1,19 +1,21 @@
1
- 'use strict';
2
-
3
- var _index = require('../../core/index');
4
-
5
- var l = _interopRequireWildcard(_index);
6
-
7
- function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
1
+ "use strict";
8
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+ var l = _interopRequireWildcard(require("../../core/index"));
5
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
6
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
7
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
8
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
9
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
10
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
11
+ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0) { ; } } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
12
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
9
13
  var getSyncRemoteData = function getSyncRemoteData() {
10
14
  return require('core/remote_data').syncRemoteData;
11
15
  };
12
-
13
16
  jest.mock('sync', function () {
14
17
  return jest.fn();
15
18
  });
16
-
17
19
  jest.mock('connection/enterprise', function () {
18
20
  return {
19
21
  isADEnabled: function isADEnabled() {
@@ -21,7 +23,6 @@ jest.mock('connection/enterprise', function () {
21
23
  }
22
24
  };
23
25
  });
24
-
25
26
  jest.mock('core/index', function () {
26
27
  return {
27
28
  useTenantInfo: function useTenantInfo() {
@@ -33,7 +34,6 @@ jest.mock('core/index', function () {
33
34
  emitEvent: jest.fn()
34
35
  };
35
36
  });
36
-
37
37
  jest.mock('core/sso/data', function () {
38
38
  return {
39
39
  fetchSSOData: jest.fn(function (id, adEnabled, cb) {
@@ -41,30 +41,24 @@ jest.mock('core/sso/data', function () {
41
41
  })
42
42
  };
43
43
  });
44
-
45
44
  describe('remote_data.syncRemoteData()', function () {
46
45
  beforeEach(function () {
47
46
  jest.clearAllMocks();
48
47
  });
49
-
50
48
  describe('calls getSSOData with AD information', function () {
51
49
  [true, false].forEach(function (isAdEnabled) {
52
- it('when isADEnabled is ' + isAdEnabled, function () {
50
+ it("when isADEnabled is ".concat(isAdEnabled), function () {
53
51
  require('connection/enterprise').isADEnabled = function () {
54
52
  return isAdEnabled;
55
53
  };
56
-
57
54
  var syncRemoteData = getSyncRemoteData();
58
55
  syncRemoteData();
59
-
60
56
  var ssoCall = require('sync').mock.calls.find(function (c) {
61
57
  return c[1] === 'sso';
62
58
  });
63
59
  ssoCall[2].syncFn('model', jest.fn());
64
-
65
- var _require$fetchSSOData = require('core/sso/data').fetchSSOData.mock.calls[0],
66
- sendADInformation = _require$fetchSSOData[1];
67
-
60
+ var _require$fetchSSOData = _slicedToArray(require('core/sso/data').fetchSSOData.mock.calls[0], 3),
61
+ sendADInformation = _require$fetchSSOData[1];
68
62
  expect(sendADInformation).toBe(isAdEnabled);
69
63
  expect(l.emitEvent).toHaveBeenCalledWith('model', 'ssodata fetched', expect.anything());
70
64
  });
@@ -1,38 +1,31 @@
1
- 'use strict';
2
-
3
- var _react = require('react');
4
-
5
- var _react2 = _interopRequireDefault(_react);
6
-
7
- var _immutable = require('immutable');
8
-
9
- var _immutable2 = _interopRequireDefault(_immutable);
10
-
11
- var _testUtils = require('testUtils');
12
-
13
- var _signed_in_confirmation = require('../../core/signed_in_confirmation');
14
-
15
- var _signed_in_confirmation2 = _interopRequireDefault(_signed_in_confirmation);
1
+ "use strict";
16
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+ var _react = _interopRequireDefault(require("react"));
5
+ var _immutable = _interopRequireDefault(require("immutable"));
6
+ var _testUtils = require("testUtils");
7
+ var _signed_in_confirmation = _interopRequireDefault(require("../../core/signed_in_confirmation"));
17
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
18
-
19
- function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; }
20
-
21
- var lock = _immutable2.default.fromJS({ id: '__lock-id__' });
22
-
9
+ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) { if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; } return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) { keys.push(key); } return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) { "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); } }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
10
+ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
11
+ function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
12
+ var lock = _immutable.default.fromJS({
13
+ id: '__lock-id__'
14
+ });
23
15
  describe('SignedInConfirmation', function () {
24
- it('renders correctly', _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
25
- return regeneratorRuntime.wrap(function _callee$(_context) {
16
+ it('renders correctly', /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
17
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
26
18
  while (1) {
27
19
  switch (_context.prev = _context.next) {
28
20
  case 0:
29
- (0, _testUtils.expectComponent)(_react2.default.createElement(_signed_in_confirmation2.default, { lock: lock })).toMatchSnapshot();
30
-
21
+ (0, _testUtils.expectComponent)( /*#__PURE__*/_react.default.createElement(_signed_in_confirmation.default, {
22
+ lock: lock
23
+ })).toMatchSnapshot();
31
24
  case 1:
32
- case 'end':
25
+ case "end":
33
26
  return _context.stop();
34
27
  }
35
28
  }
36
- }, _callee, undefined);
29
+ }, _callee);
37
30
  })));
38
31
  });