@sprucelabs/spruce-test-fixtures 62.2.24 → 62.2.26

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 (291) hide show
  1. package/build/esm/index.d.ts +1 -1
  2. package/build/esm/index.js +1 -1
  3. package/build/esm/tests/fixtures/ViewFixture.d.ts +1 -1
  4. package/build/esm/tests/routers/TestRouter.d.ts +1 -1
  5. package/build/esm/tests/routers/TestRouter.js +1 -1
  6. package/build/index.d.ts +1 -1
  7. package/build/index.js +1 -1
  8. package/build/tests/fixtures/ViewFixture.d.ts +1 -1
  9. package/build/tests/routers/TestRouter.d.ts +1 -1
  10. package/build/tests/routers/TestRouter.js +1 -1
  11. package/package.json +19 -19
  12. package/build/__tests__/behavioral/DecoratoringEmitToPassThroughProxy.test.d.ts +0 -15
  13. package/build/__tests__/behavioral/DecoratoringEmitToPassThroughProxy.test.js +0 -112
  14. package/build/__tests__/behavioral/DelaysConnectWhenOnlyUsingLoginDecorator.test.d.ts +0 -4
  15. package/build/__tests__/behavioral/DelaysConnectWhenOnlyUsingLoginDecorator.test.js +0 -34
  16. package/build/__tests__/behavioral/DisablingSchemaValidationOnTest.test.d.ts +0 -5
  17. package/build/__tests__/behavioral/DisablingSchemaValidationOnTest.test.js +0 -26
  18. package/build/__tests__/behavioral/DoesntResetAccountIfOnlySeedingLocally.test.d.ts +0 -8
  19. package/build/__tests__/behavioral/DoesntResetAccountIfOnlySeedingLocally.test.js +0 -69
  20. package/build/__tests__/behavioral/FakingEventResponses.test.d.ts +0 -12
  21. package/build/__tests__/behavioral/FakingEventResponses.test.js +0 -126
  22. package/build/__tests__/behavioral/FixtureFactory.test.d.ts +0 -7
  23. package/build/__tests__/behavioral/FixtureFactory.test.js +0 -79
  24. package/build/__tests__/behavioral/LocationFixture.test.d.ts +0 -17
  25. package/build/__tests__/behavioral/LocationFixture.test.js +0 -144
  26. package/build/__tests__/behavioral/LoginDecoratorHandlingProxiesForMe.test.d.ts +0 -12
  27. package/build/__tests__/behavioral/LoginDecoratorHandlingProxiesForMe.test.js +0 -95
  28. package/build/__tests__/behavioral/MakingSureLocalEventsAreHandledLocally.test.d.ts +0 -4
  29. package/build/__tests__/behavioral/MakingSureLocalEventsAreHandledLocally.test.js +0 -35
  30. package/build/__tests__/behavioral/MercuryFixture.test.d.ts +0 -20
  31. package/build/__tests__/behavioral/MercuryFixture.test.js +0 -187
  32. package/build/__tests__/behavioral/OrganizationFixture.test.d.ts +0 -31
  33. package/build/__tests__/behavioral/OrganizationFixture.test.js +0 -333
  34. package/build/__tests__/behavioral/PatchingConsoleErrorToErrorStream.test.d.ts +0 -4
  35. package/build/__tests__/behavioral/PatchingConsoleErrorToErrorStream.test.js +0 -21
  36. package/build/__tests__/behavioral/PersonFixture.test.d.ts +0 -22
  37. package/build/__tests__/behavioral/PersonFixture.test.js +0 -225
  38. package/build/__tests__/behavioral/PhoneNumberIncrementor.test.d.ts +0 -11
  39. package/build/__tests__/behavioral/PhoneNumberIncrementor.test.js +0 -95
  40. package/build/__tests__/behavioral/ResettingAccountLocationsInBeforeAll.test.d.ts +0 -8
  41. package/build/__tests__/behavioral/ResettingAccountLocationsInBeforeAll.test.js +0 -67
  42. package/build/__tests__/behavioral/ResettingAccountOrgsInAfterAll.test.d.ts +0 -5
  43. package/build/__tests__/behavioral/ResettingAccountOrgsInAfterAll.test.js +0 -44
  44. package/build/__tests__/behavioral/ResettingAccountOrgsInBeforeAll.test.d.ts +0 -8
  45. package/build/__tests__/behavioral/ResettingAccountOrgsInBeforeAll.test.js +0 -55
  46. package/build/__tests__/behavioral/ResettingFixtureFieldsBeforeEach.test.d.ts +0 -10
  47. package/build/__tests__/behavioral/ResettingFixtureFieldsBeforeEach.test.js +0 -137
  48. package/build/__tests__/behavioral/ResettingLocalEventListeningBeforeSeeding.test.d.ts +0 -7
  49. package/build/__tests__/behavioral/ResettingLocalEventListeningBeforeSeeding.test.js +0 -54
  50. package/build/__tests__/behavioral/RetainsContractWhenLoggingInUsingDecotorator.test.d.ts +0 -6
  51. package/build/__tests__/behavioral/RetainsContractWhenLoggingInUsingDecotorator.test.js +0 -40
  52. package/build/__tests__/behavioral/RoleFixture.test.d.ts +0 -15
  53. package/build/__tests__/behavioral/RoleFixture.test.js +0 -118
  54. package/build/__tests__/behavioral/SkillFixture.test.d.ts +0 -13
  55. package/build/__tests__/behavioral/SkillFixture.test.js +0 -118
  56. package/build/__tests__/behavioral/databases/CanUseStoresSetupInBeforeEach.test.d.ts +0 -7
  57. package/build/__tests__/behavioral/databases/CanUseStoresSetupInBeforeEach.test.js +0 -41
  58. package/build/__tests__/behavioral/databases/DatabaseFixture.test.d.ts +0 -7
  59. package/build/__tests__/behavioral/databases/DatabaseFixture.test.js +0 -59
  60. package/build/__tests__/behavioral/databases/DbResetsAsExpected.test.d.ts +0 -5
  61. package/build/__tests__/behavioral/databases/DbResetsAsExpected.test.js +0 -34
  62. package/build/__tests__/behavioral/databases/DummyStore.d.ts +0 -55
  63. package/build/__tests__/behavioral/databases/DummyStore.js +0 -36
  64. package/build/__tests__/behavioral/databases/StoreFixture.test.d.ts +0 -23
  65. package/build/__tests__/behavioral/databases/StoreFixture.test.js +0 -156
  66. package/build/__tests__/behavioral/faking/AuthenticatingAsAPerson.test.d.ts +0 -9
  67. package/build/__tests__/behavioral/faking/AuthenticatingAsAPerson.test.js +0 -73
  68. package/build/__tests__/behavioral/faking/FakeDecorator.test.d.ts +0 -45
  69. package/build/__tests__/behavioral/faking/FakeDecorator.test.js +0 -421
  70. package/build/__tests__/behavioral/faking/FakeDecoratorSetsPerson.test.d.ts +0 -4
  71. package/build/__tests__/behavioral/faking/FakeDecoratorSetsPerson.test.js +0 -23
  72. package/build/__tests__/behavioral/faking/FakeDecoratorWhoAmI.test.d.ts +0 -4
  73. package/build/__tests__/behavioral/faking/FakeDecoratorWhoAmI.test.js +0 -27
  74. package/build/__tests__/behavioral/faking/FakeThemeManager.test.d.ts +0 -8
  75. package/build/__tests__/behavioral/faking/FakeThemeManager.test.js +0 -93
  76. package/build/__tests__/behavioral/faking/FakingAddingPeopleToALocation.test.d.ts +0 -8
  77. package/build/__tests__/behavioral/faking/FakingAddingPeopleToALocation.test.js +0 -56
  78. package/build/__tests__/behavioral/faking/FakingAddingPeopleToAnOrg.test.d.ts +0 -14
  79. package/build/__tests__/behavioral/faking/FakingAddingPeopleToAnOrg.test.js +0 -141
  80. package/build/__tests__/behavioral/faking/FakingAuthenticator.test.d.ts +0 -5
  81. package/build/__tests__/behavioral/faking/FakingAuthenticator.test.js +0 -35
  82. package/build/__tests__/behavioral/faking/FakingInBeforeEach.test.d.ts +0 -6
  83. package/build/__tests__/behavioral/faking/FakingInBeforeEach.test.js +0 -42
  84. package/build/__tests__/behavioral/faking/FakingLocations.test.d.ts +0 -6
  85. package/build/__tests__/behavioral/faking/FakingLocations.test.js +0 -45
  86. package/build/__tests__/behavioral/faking/FakingRoleEvents.test.d.ts +0 -19
  87. package/build/__tests__/behavioral/faking/FakingRoleEvents.test.js +0 -140
  88. package/build/__tests__/behavioral/faking/FakingSkillEvents.test.d.ts +0 -24
  89. package/build/__tests__/behavioral/faking/FakingSkillEvents.test.js +0 -174
  90. package/build/__tests__/behavioral/faking/UpdatePerson.test.d.ts +0 -4
  91. package/build/__tests__/behavioral/faking/UpdatePerson.test.js +0 -32
  92. package/build/__tests__/behavioral/faking/UsingFakeDecorators.test.d.ts +0 -35
  93. package/build/__tests__/behavioral/faking/UsingFakeDecorators.test.js +0 -321
  94. package/build/__tests__/behavioral/faking/UsingFakesOnIncompatibleClass.test.d.ts +0 -4
  95. package/build/__tests__/behavioral/faking/UsingFakesOnIncompatibleClass.test.js +0 -48
  96. package/build/__tests__/behavioral/faking/WhoAmI.test.d.ts +0 -19
  97. package/build/__tests__/behavioral/faking/WhoAmI.test.js +0 -105
  98. package/build/__tests__/behavioral/maps/SpyingMapUtil.test.d.ts +0 -10
  99. package/build/__tests__/behavioral/maps/SpyingMapUtil.test.js +0 -76
  100. package/build/__tests__/behavioral/permissions/FakeAuthorizer.test.d.ts +0 -34
  101. package/build/__tests__/behavioral/permissions/FakeAuthorizer.test.js +0 -272
  102. package/build/__tests__/behavioral/permissions/PermissionFixture.test.d.ts +0 -5
  103. package/build/__tests__/behavioral/permissions/PermissionFixture.test.js +0 -35
  104. package/build/__tests__/behavioral/seeding/SeedingData.test.d.ts +0 -24
  105. package/build/__tests__/behavioral/seeding/SeedingData.test.js +0 -271
  106. package/build/__tests__/behavioral/seeding/UsingDecorators.test.d.ts +0 -37
  107. package/build/__tests__/behavioral/seeding/UsingDecorators.test.js +0 -266
  108. package/build/__tests__/behavioral/seeding/UsingDecoratorsToInstallSkills.test.d.ts +0 -14
  109. package/build/__tests__/behavioral/seeding/UsingDecoratorsToInstallSkills.test.js +0 -117
  110. package/build/__tests__/behavioral/views/FakingSkillViewControllers.test.d.ts +0 -12
  111. package/build/__tests__/behavioral/views/FakingSkillViewControllers.test.js +0 -55
  112. package/build/__tests__/behavioral/views/Routing.test.d.ts +0 -36
  113. package/build/__tests__/behavioral/views/Routing.test.js +0 -177
  114. package/build/__tests__/behavioral/views/TestingScope.test.d.ts +0 -24
  115. package/build/__tests__/behavioral/views/TestingScope.test.js +0 -197
  116. package/build/__tests__/behavioral/views/ViewPlugins.test.d.ts +0 -12
  117. package/build/__tests__/behavioral/views/ViewPlugins.test.js +0 -83
  118. package/build/__tests__/behavioral/views/WorkingWithTimezones.test.d.ts +0 -11
  119. package/build/__tests__/behavioral/views/WorkingWithTimezones.test.js +0 -55
  120. package/build/__tests__/behavioral/views/viewFixture/ViewFixture.test.d.ts +0 -118
  121. package/build/__tests__/behavioral/views/viewFixture/ViewFixture.test.js +0 -761
  122. package/build/__tests__/behavioral/views/viewFixture/ViewFixtureLetsYouOverrideViewControllerFactory.test.d.ts +0 -5
  123. package/build/__tests__/behavioral/views/viewFixture/ViewFixtureLetsYouOverrideViewControllerFactory.test.js +0 -29
  124. package/build/__tests__/support/AbstractFakeDecoratorTest.d.ts +0 -5
  125. package/build/__tests__/support/AbstractFakeDecoratorTest.js +0 -27
  126. package/build/__tests__/support/EventFaker.d.ts +0 -5
  127. package/build/__tests__/support/EventFaker.js +0 -36
  128. package/build/__tests__/support/RandomViewPlugin.d.ts +0 -2
  129. package/build/__tests__/support/RandomViewPlugin.js +0 -5
  130. package/build/__tests__/support/RandomViewPlugin2.d.ts +0 -2
  131. package/build/__tests__/support/RandomViewPlugin2.js +0 -5
  132. package/build/__tests__/testDirsAndFiles/one-good-store-skill/build/.spruce/stores/stores.d.ts +0 -5
  133. package/build/__tests__/testDirsAndFiles/one-good-store-skill/build/.spruce/stores/stores.js +0 -9
  134. package/build/__tests__/testDirsAndFiles/one-good-store-skill/build/stores/Good.store.d.ts +0 -51
  135. package/build/__tests__/testDirsAndFiles/one-good-store-skill/build/stores/Good.store.js +0 -33
  136. package/build/__tests__/testDirsAndFiles/one-good-store-skill/src/.spruce/settings.json +0 -6
  137. package/build/__tests__/testDirsAndFiles/plugins1/build/.spruce/views/views.d.ts +0 -6
  138. package/build/__tests__/testDirsAndFiles/plugins1/build/.spruce/views/views.js +0 -11
  139. package/build/__tests__/testDirsAndFiles/plugins2/build/.spruce/views/views.d.ts +0 -6
  140. package/build/__tests__/testDirsAndFiles/plugins2/build/.spruce/views/views.js +0 -11
  141. package/build/__tests__/testDirsAndFiles/skill/build/.spruce/views/views.js +0 -18
  142. package/build/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Book.svc.d.ts +0 -5
  143. package/build/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Book.svc.js +0 -11
  144. package/build/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Spy.svc.d.ts +0 -7
  145. package/build/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Spy.svc.js +0 -19
  146. package/build/__tests__/testDirsAndFiles/skill/build/viewControllers/BookForm.vc.d.ts +0 -8
  147. package/build/__tests__/testDirsAndFiles/skill/build/viewControllers/BookForm.vc.js +0 -31
  148. package/build/__tests__/testDirsAndFiles/skill/package.json +0 -5
  149. package/build/__tests__/testDirsAndFiles/skill/src/.spruce/settings.json +0 -6
  150. package/build/__tests__/testDirsAndFiles/skill/src/.spruce/views/views.d.ts +0 -7
  151. package/build/__tests__/testDirsAndFiles/skill/src/.spruce/views/views.js +0 -17
  152. package/build/__tests__/testDirsAndFiles/skill/src/skillViewControllers/Book.svc.d.ts +0 -5
  153. package/build/__tests__/testDirsAndFiles/skill/src/skillViewControllers/Book.svc.js +0 -11
  154. package/build/__tests__/testDirsAndFiles/skill/src/viewControllers/BookForm.vc.d.ts +0 -8
  155. package/build/__tests__/testDirsAndFiles/skill/src/viewControllers/BookForm.vc.js +0 -31
  156. package/build/esm/__tests__/behavioral/DecoratoringEmitToPassThroughProxy.test.d.ts +0 -15
  157. package/build/esm/__tests__/behavioral/DecoratoringEmitToPassThroughProxy.test.js +0 -128
  158. package/build/esm/__tests__/behavioral/DelaysConnectWhenOnlyUsingLoginDecorator.test.d.ts +0 -4
  159. package/build/esm/__tests__/behavioral/DelaysConnectWhenOnlyUsingLoginDecorator.test.js +0 -40
  160. package/build/esm/__tests__/behavioral/DisablingSchemaValidationOnTest.test.d.ts +0 -5
  161. package/build/esm/__tests__/behavioral/DisablingSchemaValidationOnTest.test.js +0 -23
  162. package/build/esm/__tests__/behavioral/DoesntResetAccountIfOnlySeedingLocally.test.d.ts +0 -8
  163. package/build/esm/__tests__/behavioral/DoesntResetAccountIfOnlySeedingLocally.test.js +0 -80
  164. package/build/esm/__tests__/behavioral/FakingEventResponses.test.d.ts +0 -12
  165. package/build/esm/__tests__/behavioral/FakingEventResponses.test.js +0 -148
  166. package/build/esm/__tests__/behavioral/FixtureFactory.test.d.ts +0 -7
  167. package/build/esm/__tests__/behavioral/FixtureFactory.test.js +0 -61
  168. package/build/esm/__tests__/behavioral/LocationFixture.test.d.ts +0 -17
  169. package/build/esm/__tests__/behavioral/LocationFixture.test.js +0 -173
  170. package/build/esm/__tests__/behavioral/LoginDecoratorHandlingProxiesForMe.test.d.ts +0 -12
  171. package/build/esm/__tests__/behavioral/LoginDecoratorHandlingProxiesForMe.test.js +0 -113
  172. package/build/esm/__tests__/behavioral/MakingSureLocalEventsAreHandledLocally.test.d.ts +0 -4
  173. package/build/esm/__tests__/behavioral/MakingSureLocalEventsAreHandledLocally.test.js +0 -41
  174. package/build/esm/__tests__/behavioral/MercuryFixture.test.d.ts +0 -20
  175. package/build/esm/__tests__/behavioral/MercuryFixture.test.js +0 -223
  176. package/build/esm/__tests__/behavioral/OrganizationFixture.test.d.ts +0 -31
  177. package/build/esm/__tests__/behavioral/OrganizationFixture.test.js +0 -389
  178. package/build/esm/__tests__/behavioral/PatchingConsoleErrorToErrorStream.test.d.ts +0 -4
  179. package/build/esm/__tests__/behavioral/PatchingConsoleErrorToErrorStream.test.js +0 -18
  180. package/build/esm/__tests__/behavioral/PersonFixture.test.d.ts +0 -22
  181. package/build/esm/__tests__/behavioral/PersonFixture.test.js +0 -232
  182. package/build/esm/__tests__/behavioral/PhoneNumberIncrementor.test.d.ts +0 -11
  183. package/build/esm/__tests__/behavioral/PhoneNumberIncrementor.test.js +0 -112
  184. package/build/esm/__tests__/behavioral/ResettingAccountLocationsInBeforeAll.test.d.ts +0 -8
  185. package/build/esm/__tests__/behavioral/ResettingAccountLocationsInBeforeAll.test.js +0 -84
  186. package/build/esm/__tests__/behavioral/ResettingAccountOrgsInAfterAll.test.d.ts +0 -5
  187. package/build/esm/__tests__/behavioral/ResettingAccountOrgsInAfterAll.test.js +0 -55
  188. package/build/esm/__tests__/behavioral/ResettingAccountOrgsInBeforeAll.test.d.ts +0 -8
  189. package/build/esm/__tests__/behavioral/ResettingAccountOrgsInBeforeAll.test.js +0 -72
  190. package/build/esm/__tests__/behavioral/ResettingFixtureFieldsBeforeEach.test.d.ts +0 -10
  191. package/build/esm/__tests__/behavioral/ResettingFixtureFieldsBeforeEach.test.js +0 -146
  192. package/build/esm/__tests__/behavioral/ResettingLocalEventListeningBeforeSeeding.test.d.ts +0 -7
  193. package/build/esm/__tests__/behavioral/ResettingLocalEventListeningBeforeSeeding.test.js +0 -66
  194. package/build/esm/__tests__/behavioral/RetainsContractWhenLoggingInUsingDecotorator.test.d.ts +0 -6
  195. package/build/esm/__tests__/behavioral/RetainsContractWhenLoggingInUsingDecotorator.test.js +0 -51
  196. package/build/esm/__tests__/behavioral/RoleFixture.test.d.ts +0 -15
  197. package/build/esm/__tests__/behavioral/RoleFixture.test.js +0 -143
  198. package/build/esm/__tests__/behavioral/SkillFixture.test.d.ts +0 -13
  199. package/build/esm/__tests__/behavioral/SkillFixture.test.js +0 -141
  200. package/build/esm/__tests__/behavioral/databases/CanUseStoresSetupInBeforeEach.test.d.ts +0 -7
  201. package/build/esm/__tests__/behavioral/databases/CanUseStoresSetupInBeforeEach.test.js +0 -53
  202. package/build/esm/__tests__/behavioral/databases/DatabaseFixture.test.d.ts +0 -7
  203. package/build/esm/__tests__/behavioral/databases/DatabaseFixture.test.js +0 -48
  204. package/build/esm/__tests__/behavioral/databases/DbResetsAsExpected.test.d.ts +0 -5
  205. package/build/esm/__tests__/behavioral/databases/DbResetsAsExpected.test.js +0 -28
  206. package/build/esm/__tests__/behavioral/databases/DummyStore.d.ts +0 -55
  207. package/build/esm/__tests__/behavioral/databases/DummyStore.js +0 -43
  208. package/build/esm/__tests__/behavioral/databases/StoreFixture.test.d.ts +0 -23
  209. package/build/esm/__tests__/behavioral/databases/StoreFixture.test.js +0 -164
  210. package/build/esm/__tests__/behavioral/faking/AuthenticatingAsAPerson.test.d.ts +0 -9
  211. package/build/esm/__tests__/behavioral/faking/AuthenticatingAsAPerson.test.js +0 -89
  212. package/build/esm/__tests__/behavioral/faking/FakeDecorator.test.d.ts +0 -45
  213. package/build/esm/__tests__/behavioral/faking/FakeDecorator.test.js +0 -482
  214. package/build/esm/__tests__/behavioral/faking/FakeDecoratorSetsPerson.test.d.ts +0 -4
  215. package/build/esm/__tests__/behavioral/faking/FakeDecoratorSetsPerson.test.js +0 -28
  216. package/build/esm/__tests__/behavioral/faking/FakeDecoratorWhoAmI.test.d.ts +0 -4
  217. package/build/esm/__tests__/behavioral/faking/FakeDecoratorWhoAmI.test.js +0 -32
  218. package/build/esm/__tests__/behavioral/faking/FakeThemeManager.test.d.ts +0 -8
  219. package/build/esm/__tests__/behavioral/faking/FakeThemeManager.test.js +0 -82
  220. package/build/esm/__tests__/behavioral/faking/FakingAddingPeopleToALocation.test.d.ts +0 -8
  221. package/build/esm/__tests__/behavioral/faking/FakingAddingPeopleToALocation.test.js +0 -70
  222. package/build/esm/__tests__/behavioral/faking/FakingAddingPeopleToAnOrg.test.d.ts +0 -14
  223. package/build/esm/__tests__/behavioral/faking/FakingAddingPeopleToAnOrg.test.js +0 -165
  224. package/build/esm/__tests__/behavioral/faking/FakingAuthenticator.test.d.ts +0 -5
  225. package/build/esm/__tests__/behavioral/faking/FakingAuthenticator.test.js +0 -43
  226. package/build/esm/__tests__/behavioral/faking/FakingInBeforeEach.test.d.ts +0 -6
  227. package/build/esm/__tests__/behavioral/faking/FakingInBeforeEach.test.js +0 -55
  228. package/build/esm/__tests__/behavioral/faking/FakingLocations.test.d.ts +0 -6
  229. package/build/esm/__tests__/behavioral/faking/FakingLocations.test.js +0 -55
  230. package/build/esm/__tests__/behavioral/faking/FakingRoleEvents.test.d.ts +0 -19
  231. package/build/esm/__tests__/behavioral/faking/FakingRoleEvents.test.js +0 -175
  232. package/build/esm/__tests__/behavioral/faking/FakingSkillEvents.test.d.ts +0 -24
  233. package/build/esm/__tests__/behavioral/faking/FakingSkillEvents.test.js +0 -214
  234. package/build/esm/__tests__/behavioral/faking/UpdatePerson.test.d.ts +0 -4
  235. package/build/esm/__tests__/behavioral/faking/UpdatePerson.test.js +0 -38
  236. package/build/esm/__tests__/behavioral/faking/UsingFakeDecorators.test.d.ts +0 -35
  237. package/build/esm/__tests__/behavioral/faking/UsingFakeDecorators.test.js +0 -360
  238. package/build/esm/__tests__/behavioral/faking/UsingFakesOnIncompatibleClass.test.d.ts +0 -4
  239. package/build/esm/__tests__/behavioral/faking/UsingFakesOnIncompatibleClass.test.js +0 -31
  240. package/build/esm/__tests__/behavioral/faking/WhoAmI.test.d.ts +0 -19
  241. package/build/esm/__tests__/behavioral/faking/WhoAmI.test.js +0 -142
  242. package/build/esm/__tests__/behavioral/maps/SpyingMapUtil.test.d.ts +0 -10
  243. package/build/esm/__tests__/behavioral/maps/SpyingMapUtil.test.js +0 -94
  244. package/build/esm/__tests__/behavioral/permissions/FakeAuthorizer.test.d.ts +0 -34
  245. package/build/esm/__tests__/behavioral/permissions/FakeAuthorizer.test.js +0 -324
  246. package/build/esm/__tests__/behavioral/permissions/PermissionFixture.test.d.ts +0 -5
  247. package/build/esm/__tests__/behavioral/permissions/PermissionFixture.test.js +0 -43
  248. package/build/esm/__tests__/behavioral/seeding/SeedingData.test.d.ts +0 -24
  249. package/build/esm/__tests__/behavioral/seeding/SeedingData.test.js +0 -314
  250. package/build/esm/__tests__/behavioral/seeding/UsingDecorators.test.d.ts +0 -37
  251. package/build/esm/__tests__/behavioral/seeding/UsingDecorators.test.js +0 -322
  252. package/build/esm/__tests__/behavioral/seeding/UsingDecoratorsToInstallSkills.test.d.ts +0 -14
  253. package/build/esm/__tests__/behavioral/seeding/UsingDecoratorsToInstallSkills.test.js +0 -138
  254. package/build/esm/__tests__/behavioral/views/FakingSkillViewControllers.test.d.ts +0 -12
  255. package/build/esm/__tests__/behavioral/views/FakingSkillViewControllers.test.js +0 -70
  256. package/build/esm/__tests__/behavioral/views/Routing.test.d.ts +0 -36
  257. package/build/esm/__tests__/behavioral/views/Routing.test.js +0 -212
  258. package/build/esm/__tests__/behavioral/views/TestingScope.test.d.ts +0 -24
  259. package/build/esm/__tests__/behavioral/views/TestingScope.test.js +0 -238
  260. package/build/esm/__tests__/behavioral/views/ViewPlugins.test.d.ts +0 -12
  261. package/build/esm/__tests__/behavioral/views/ViewPlugins.test.js +0 -103
  262. package/build/esm/__tests__/behavioral/views/WorkingWithTimezones.test.d.ts +0 -11
  263. package/build/esm/__tests__/behavioral/views/WorkingWithTimezones.test.js +0 -64
  264. package/build/esm/__tests__/behavioral/views/viewFixture/ViewFixture.test.d.ts +0 -118
  265. package/build/esm/__tests__/behavioral/views/viewFixture/ViewFixture.test.js +0 -856
  266. package/build/esm/__tests__/behavioral/views/viewFixture/ViewFixtureLetsYouOverrideViewControllerFactory.test.d.ts +0 -5
  267. package/build/esm/__tests__/behavioral/views/viewFixture/ViewFixtureLetsYouOverrideViewControllerFactory.test.js +0 -39
  268. package/build/esm/__tests__/support/AbstractFakeDecoratorTest.d.ts +0 -5
  269. package/build/esm/__tests__/support/AbstractFakeDecoratorTest.js +0 -34
  270. package/build/esm/__tests__/support/EventFaker.d.ts +0 -5
  271. package/build/esm/__tests__/support/EventFaker.js +0 -45
  272. package/build/esm/__tests__/support/RandomViewPlugin.d.ts +0 -2
  273. package/build/esm/__tests__/support/RandomViewPlugin.js +0 -2
  274. package/build/esm/__tests__/support/RandomViewPlugin2.d.ts +0 -2
  275. package/build/esm/__tests__/support/RandomViewPlugin2.js +0 -2
  276. package/build/esm/__tests__/testDirsAndFiles/one-good-store-skill/build/stores/Good.store.d.ts +0 -51
  277. package/build/esm/__tests__/testDirsAndFiles/one-good-store-skill/build/stores/Good.store.js +0 -41
  278. package/build/esm/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Book.svc.d.ts +0 -5
  279. package/build/esm/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Book.svc.js +0 -9
  280. package/build/esm/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Spy.svc.d.ts +0 -7
  281. package/build/esm/__tests__/testDirsAndFiles/skill/build/skillViewControllers/Spy.svc.js +0 -28
  282. package/build/esm/__tests__/testDirsAndFiles/skill/build/viewControllers/BookForm.vc.d.ts +0 -8
  283. package/build/esm/__tests__/testDirsAndFiles/skill/build/viewControllers/BookForm.vc.js +0 -26
  284. package/build/esm/__tests__/testDirsAndFiles/skill/src/skillViewControllers/Book.svc.d.ts +0 -5
  285. package/build/esm/__tests__/testDirsAndFiles/skill/src/skillViewControllers/Book.svc.js +0 -9
  286. package/build/esm/__tests__/testDirsAndFiles/skill/src/viewControllers/BookForm.vc.d.ts +0 -8
  287. package/build/esm/__tests__/testDirsAndFiles/skill/src/viewControllers/BookForm.vc.js +0 -26
  288. /package/build/{__tests__/support → esm/tests}/FakeThemeManager.d.ts +0 -0
  289. /package/build/esm/{__tests__/support → tests}/FakeThemeManager.js +0 -0
  290. /package/build/{esm/__tests__/support → tests}/FakeThemeManager.d.ts +0 -0
  291. /package/build/{__tests__/support → tests}/FakeThemeManager.js +0 -0
@@ -1,79 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
19
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
20
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
21
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
22
- return c > 3 && r && Object.defineProperty(target, key, r), r;
23
- };
24
- var __importStar = (this && this.__importStar) || function (mod) {
25
- if (mod && mod.__esModule) return mod;
26
- var result = {};
27
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
28
- __setModuleDefault(result, mod);
29
- return result;
30
- };
31
- var __importDefault = (this && this.__importDefault) || function (mod) {
32
- return (mod && mod.__esModule) ? mod : { "default": mod };
33
- };
34
- Object.defineProperty(exports, "__esModule", { value: true });
35
- const test_utils_1 = __importStar(require("@sprucelabs/test-utils"));
36
- const test_utils_2 = require("@sprucelabs/test-utils");
37
- const FixtureFactory_1 = __importDefault(require("../../tests/fixtures/FixtureFactory"));
38
- const MercuryFixture_1 = __importDefault(require("../../tests/fixtures/MercuryFixture"));
39
- const OrganizationFixture_1 = __importDefault(require("../../tests/fixtures/OrganizationFixture"));
40
- const PersonFixture_1 = __importDefault(require("../../tests/fixtures/PersonFixture"));
41
- const SkillFixture_1 = __importDefault(require("../../tests/fixtures/SkillFixture"));
42
- class FixtureFactoryTest extends test_utils_1.default {
43
- static throwsWithBadFixture() {
44
- //@ts-ignore
45
- const err = test_utils_1.assert.doesThrow(() => this.Fixture().Fixture('taco'));
46
- test_utils_2.errorAssert.assertError(err, 'INVALID_FIXTURE', {
47
- suppliedName: 'taco',
48
- });
49
- }
50
- static getsFixture(name, Class) {
51
- //@ts-ignore
52
- const fixture = this.Fixture().Fixture(name);
53
- test_utils_1.assert.isTrue(fixture instanceof Class);
54
- }
55
- static Fixture() {
56
- return new FixtureFactory_1.default({ cwd: this.cwd });
57
- }
58
- static async destroyDisconnectsClient() {
59
- const { client } = await this.Fixture()
60
- .Fixture('person')
61
- .loginAsDemoPerson();
62
- test_utils_1.assert.isTrue(client.isConnected());
63
- await FixtureFactory_1.default.destroy();
64
- test_utils_1.assert.isFalse(client.isConnected());
65
- }
66
- }
67
- exports.default = FixtureFactoryTest;
68
- __decorate([
69
- (0, test_utils_1.test)()
70
- ], FixtureFactoryTest, "throwsWithBadFixture", null);
71
- __decorate([
72
- (0, test_utils_1.test)('person fixture', 'person', PersonFixture_1.default),
73
- (0, test_utils_1.test)('mercury fixture', 'mercury', MercuryFixture_1.default),
74
- (0, test_utils_1.test)('org fixture', 'organization', OrganizationFixture_1.default),
75
- (0, test_utils_1.test)('skill fixture', 'skill', SkillFixture_1.default)
76
- ], FixtureFactoryTest, "getsFixture", null);
77
- __decorate([
78
- (0, test_utils_1.test)()
79
- ], FixtureFactoryTest, "destroyDisconnectsClient", null);
@@ -1,17 +0,0 @@
1
- import AbstractSpruceFixtureTest from '../../tests/AbstractSpruceFixtureTest';
2
- export default class LocationFixtureTest extends AbstractSpruceFixtureTest {
3
- protected static beforeEach(): Promise<void>;
4
- protected static canCreateWithSpecificOrg(): Promise<void>;
5
- protected static canCreatLocationWithNoParams(): Promise<void>;
6
- protected static isNotPartOfLocationToStart(): Promise<void>;
7
- protected static uniqueLocationName(): Promise<void>;
8
- protected static locationCountResetBeforeEach(): Promise<void>;
9
- protected static canAddPersonToLocation(): Promise<void>;
10
- protected static throwsWhenTryingToRemovePersonWithBadIds(): Promise<void>;
11
- protected static canRemoveRole(): Promise<void>;
12
- private static isPersonPartOfLocation;
13
- protected static seedLocationAndAddPerson(): Promise<{
14
- location: Pick<import("@sprucelabs/schema").SchemaStaticValues<import("@sprucelabs/mercury-types").SpruceSchemas.Spruce.v2020_07_22.LocationSchema, false, import("@sprucelabs/schema").SchemaOptionalFieldNames<import("@sprucelabs/mercury-types").SpruceSchemas.Spruce.v2020_07_22.LocationSchema>, import("@sprucelabs/schema").StaticSchemaAllValues<import("@sprucelabs/mercury-types").SpruceSchemas.Spruce.v2020_07_22.LocationSchema, false>>, "id" | "address" | "phone" | "name" | "organizationId" | "timezone" | "dateCreated" | "dateDeleted" | "isPublic" | "slug" | "num">;
15
- person: import("@sprucelabs/mercury-types").SpruceSchemas.Spruce.v2020_07_22.Person;
16
- }>;
17
- }
@@ -1,144 +0,0 @@
1
- "use strict";
2
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
- return c > 3 && r && Object.defineProperty(target, key, r), r;
7
- };
8
- var __importDefault = (this && this.__importDefault) || function (mod) {
9
- return (mod && mod.__esModule) ? mod : { "default": mod };
10
- };
11
- var LocationFixtureTest_1;
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- const test_utils_1 = require("@sprucelabs/test-utils");
14
- const AbstractSpruceFixtureTest_1 = __importDefault(require("../../tests/AbstractSpruceFixtureTest"));
15
- const constants_1 = require("../../tests/constants");
16
- const fake_1 = __importDefault(require("../../tests/decorators/fake"));
17
- const LocationFixture_1 = __importDefault(require("../../tests/fixtures/LocationFixture"));
18
- let LocationFixtureTest = LocationFixtureTest_1 = class LocationFixtureTest extends AbstractSpruceFixtureTest_1.default {
19
- static async beforeEach() {
20
- await super.beforeEach();
21
- await this.seeder.resetAccount();
22
- await this.seeder.resetAccount(constants_1.DEMO_NUMBER_LOCATION_FIXTURE_OUTSIDER);
23
- }
24
- static async canCreateWithSpecificOrg() {
25
- const org = await this.organizations.seedDemoOrganization({
26
- name: 'Location fixture org',
27
- });
28
- const location = await this.locations.seedDemoLocation({
29
- name: 'Location fixture location',
30
- organizationId: org.id,
31
- });
32
- test_utils_1.assert.isEqual(org.id, location.organizationId);
33
- }
34
- static async canCreatLocationWithNoParams() {
35
- const location = await this.locations.seedDemoLocation({});
36
- test_utils_1.assert.isTruthy(location);
37
- }
38
- static async isNotPartOfLocationToStart() {
39
- const location = await this.locations.seedDemoLocation({
40
- name: 'Location fixture location',
41
- });
42
- const { person } = await this.people.loginAsDemoPerson(constants_1.DEMO_NUMBER_LOCATION_FIXTURE_OUTSIDER);
43
- const isHired = await this.locations.isPartOfLocation({
44
- personId: person.id,
45
- locationId: location.id,
46
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
47
- });
48
- test_utils_1.assert.isFalse(isHired);
49
- }
50
- static async uniqueLocationName() {
51
- const location1 = await this.locations.seedDemoLocation({});
52
- const location2 = await this.locations.seedDemoLocation({});
53
- test_utils_1.assert.isNotEqual(location1.name, location2.name);
54
- }
55
- static async locationCountResetBeforeEach() {
56
- //@ts-ignore
57
- test_utils_1.assert.isEqual(LocationFixture_1.default.locationCount, 0);
58
- }
59
- static async canAddPersonToLocation() {
60
- const { person, location } = await this.seedLocationAndAddPerson();
61
- const isHired = await LocationFixtureTest_1.isPersonPartOfLocation(person.id, location.id);
62
- test_utils_1.assert.isTrue(isHired);
63
- }
64
- static async throwsWhenTryingToRemovePersonWithBadIds() {
65
- await test_utils_1.assert.doesThrowAsync(() => this.locations.removePerson({
66
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
67
- personId: 'aoeu',
68
- locationId: 'aoeu',
69
- roleBase: 'test',
70
- organizationId: '234',
71
- }));
72
- }
73
- static async canRemoveRole() {
74
- const { person, location } = await this.seedLocationAndAddPerson();
75
- await this.locations.removePerson({
76
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
77
- personId: person.id,
78
- locationId: location.id,
79
- organizationId: location.organizationId,
80
- roleBase: 'guest',
81
- });
82
- const isHired = await this.isPersonPartOfLocation(person.id, location.id);
83
- test_utils_1.assert.isFalse(isHired);
84
- }
85
- static async isPersonPartOfLocation(personId, locationId) {
86
- return await this.locations.isPartOfLocation({
87
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
88
- personId,
89
- locationId,
90
- });
91
- }
92
- static async seedLocationAndAddPerson() {
93
- const org = await this.organizations.seedDemoOrganization({
94
- name: 'Location fixture org',
95
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
96
- });
97
- await this.organizations.seedDemoOrganization({
98
- name: 'Outside org',
99
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE_OUTSIDER,
100
- });
101
- const location = await this.locations.seedDemoLocation({
102
- name: 'Location fixture location',
103
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
104
- organizationId: org.id,
105
- });
106
- const { person } = await this.people.loginAsDemoPerson(constants_1.DEMO_NUMBER_LOCATION_FIXTURE_OUTSIDER);
107
- await this.locations.addPerson({
108
- personId: person.id,
109
- organizationId: org.id,
110
- locationId: location.id,
111
- roleBase: 'guest',
112
- phone: constants_1.DEMO_NUMBER_LOCATION_FIXTURE,
113
- });
114
- return { location, person };
115
- }
116
- };
117
- __decorate([
118
- (0, test_utils_1.test)()
119
- ], LocationFixtureTest, "canCreateWithSpecificOrg", null);
120
- __decorate([
121
- (0, test_utils_1.test)()
122
- ], LocationFixtureTest, "canCreatLocationWithNoParams", null);
123
- __decorate([
124
- (0, test_utils_1.test)()
125
- ], LocationFixtureTest, "isNotPartOfLocationToStart", null);
126
- __decorate([
127
- (0, test_utils_1.test)()
128
- ], LocationFixtureTest, "uniqueLocationName", null);
129
- __decorate([
130
- (0, test_utils_1.test)()
131
- ], LocationFixtureTest, "locationCountResetBeforeEach", null);
132
- __decorate([
133
- (0, test_utils_1.test)()
134
- ], LocationFixtureTest, "canAddPersonToLocation", null);
135
- __decorate([
136
- (0, test_utils_1.test)()
137
- ], LocationFixtureTest, "throwsWhenTryingToRemovePersonWithBadIds", null);
138
- __decorate([
139
- (0, test_utils_1.test)()
140
- ], LocationFixtureTest, "canRemoveRole", null);
141
- LocationFixtureTest = LocationFixtureTest_1 = __decorate([
142
- fake_1.default.login(constants_1.DEMO_NUMBER_LOCATION_FIXTURE)
143
- ], LocationFixtureTest);
144
- exports.default = LocationFixtureTest;
@@ -1,12 +0,0 @@
1
- import AbstractSpruceFixtureTest from '../../tests/AbstractSpruceFixtureTest';
2
- export default class LoginDecoratorHandlingProxiesForMeTest extends AbstractSpruceFixtureTest {
3
- private static lastToken?;
4
- protected static proxyTokenGeneratorReturnsExpectedProxyToken(expected: string): Promise<void>;
5
- protected static onlyEmitsEventOnce(): Promise<void>;
6
- protected static tokenSetBackAfterEachTest(): Promise<void>;
7
- protected static tokenBackToOriginLoggedInPerson(): Promise<void>;
8
- protected static loggingAnAsDemoPerson2AgainSetsValidProxy(): Promise<void>;
9
- private static getDecorator;
10
- private static generateToken;
11
- private static loginAsSecondPerson;
12
- }
@@ -1,95 +0,0 @@
1
- "use strict";
2
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
- return c > 3 && r && Object.defineProperty(target, key, r), r;
7
- };
8
- var __importDefault = (this && this.__importDefault) || function (mod) {
9
- return (mod && mod.__esModule) ? mod : { "default": mod };
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const spruce_event_utils_1 = require("@sprucelabs/spruce-event-utils");
13
- const test_utils_1 = require("@sprucelabs/test-utils");
14
- const ClientProxyDecorator_1 = __importDefault(require("../../ClientProxyDecorator"));
15
- const AbstractSpruceFixtureTest_1 = __importDefault(require("../../tests/AbstractSpruceFixtureTest"));
16
- const constants_1 = require("../../tests/constants");
17
- const login_1 = __importDefault(require("../../tests/decorators/login"));
18
- const MercuryFixture_1 = __importDefault(require("../../tests/fixtures/MercuryFixture"));
19
- MercuryFixture_1.default.setShouldRequireLocalListeners(false);
20
- let LoginDecoratorHandlingProxiesForMeTest = class LoginDecoratorHandlingProxiesForMeTest extends AbstractSpruceFixtureTest_1.default {
21
- static async proxyTokenGeneratorReturnsExpectedProxyToken(expected) {
22
- await login_1.default.getClient().on('register-proxy-token::v2020_12_25', () => {
23
- return {
24
- token: expected,
25
- };
26
- });
27
- const token = await this.generateToken();
28
- test_utils_1.assert.isEqual(token, expected);
29
- }
30
- static async onlyEmitsEventOnce() {
31
- let hitCount = 0;
32
- await login_1.default.getClient().on('register-proxy-token::v2020_12_25', () => {
33
- hitCount++;
34
- return {
35
- token: 'aoeu',
36
- };
37
- });
38
- const generator = this.getDecorator().getProxyTokenGenerator();
39
- await (generator === null || generator === void 0 ? void 0 : generator());
40
- test_utils_1.assert.isEqual(hitCount, 0);
41
- await (generator === null || generator === void 0 ? void 0 : generator());
42
- await (generator === null || generator === void 0 ? void 0 : generator());
43
- test_utils_1.assert.isEqual(hitCount, 0);
44
- }
45
- static async tokenSetBackAfterEachTest() {
46
- this.lastToken = await this.generateToken();
47
- await this.loginAsSecondPerson();
48
- const newToken = await this.generateToken();
49
- test_utils_1.assert.isNotEqual(this.lastToken, newToken);
50
- }
51
- static async tokenBackToOriginLoggedInPerson() {
52
- const token = await this.generateToken();
53
- test_utils_1.assert.isEqual(this.lastToken, token);
54
- }
55
- static async loggingAnAsDemoPerson2AgainSetsValidProxy() {
56
- const { client } = await this.loginAsSecondPerson();
57
- const token = await this.generateToken();
58
- const results = await client.emit('whoami::v2020_12_25', {
59
- source: {
60
- proxyToken: token,
61
- },
62
- });
63
- spruce_event_utils_1.eventResponseUtil.getFirstResponseOrThrow(results);
64
- }
65
- static getDecorator() {
66
- return ClientProxyDecorator_1.default.getInstance();
67
- }
68
- static async generateToken() {
69
- const generator = this.getDecorator().getProxyTokenGenerator();
70
- const token = await (generator === null || generator === void 0 ? void 0 : generator());
71
- return token;
72
- }
73
- static async loginAsSecondPerson() {
74
- return this.Fixture('view').loginAsDemoPerson(constants_1.DEMO_NUMBER_LOGIN_DECORATOR_2);
75
- }
76
- };
77
- __decorate([
78
- (0, test_utils_1.test)('proxy set to random', `${Math.random() * new Date().getTime()}`)
79
- ], LoginDecoratorHandlingProxiesForMeTest, "proxyTokenGeneratorReturnsExpectedProxyToken", null);
80
- __decorate([
81
- (0, test_utils_1.test)()
82
- ], LoginDecoratorHandlingProxiesForMeTest, "onlyEmitsEventOnce", null);
83
- __decorate([
84
- (0, test_utils_1.test)()
85
- ], LoginDecoratorHandlingProxiesForMeTest, "tokenSetBackAfterEachTest", null);
86
- __decorate([
87
- (0, test_utils_1.test)()
88
- ], LoginDecoratorHandlingProxiesForMeTest, "tokenBackToOriginLoggedInPerson", null);
89
- __decorate([
90
- (0, test_utils_1.test)()
91
- ], LoginDecoratorHandlingProxiesForMeTest, "loggingAnAsDemoPerson2AgainSetsValidProxy", null);
92
- LoginDecoratorHandlingProxiesForMeTest = __decorate([
93
- (0, login_1.default)(constants_1.DEMO_NUMBER_LOGIN_DECORATOR)
94
- ], LoginDecoratorHandlingProxiesForMeTest);
95
- exports.default = LoginDecoratorHandlingProxiesForMeTest;
@@ -1,4 +0,0 @@
1
- import AbstractSpruceFixtureTest from '../../tests/AbstractSpruceFixtureTest';
2
- export default class MakingSureLocalEventsAreHandledLocallyTest extends AbstractSpruceFixtureTest {
3
- protected static throwsWhenNoListenerSetForLocalEvent(): Promise<void>;
4
- }
@@ -1,35 +0,0 @@
1
- "use strict";
2
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
- return c > 3 && r && Object.defineProperty(target, key, r), r;
7
- };
8
- var __importDefault = (this && this.__importDefault) || function (mod) {
9
- return (mod && mod.__esModule) ? mod : { "default": mod };
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const mercury_client_1 = require("@sprucelabs/mercury-client");
13
- const spruce_skill_utils_1 = require("@sprucelabs/spruce-skill-utils");
14
- const test_utils_1 = require("@sprucelabs/test-utils");
15
- const AbstractSpruceFixtureTest_1 = __importDefault(require("../../tests/AbstractSpruceFixtureTest"));
16
- const constants_1 = require("../../tests/constants");
17
- const login_1 = __importDefault(require("../../tests/decorators/login"));
18
- const MercuryFixture_1 = __importDefault(require("../../tests/fixtures/MercuryFixture"));
19
- MercuryFixture_1.default.setShouldRequireLocalListeners(false);
20
- let MakingSureLocalEventsAreHandledLocallyTest = class MakingSureLocalEventsAreHandledLocallyTest extends AbstractSpruceFixtureTest_1.default {
21
- static async throwsWhenNoListenerSetForLocalEvent() {
22
- await this.SkillFromTestDir('skill');
23
- const skill = await this.skills.seedDemoSkill();
24
- spruce_skill_utils_1.AuthService.Auth(this.cwd).updateCurrentSkill(skill);
25
- await MercuryFixture_1.default.beforeEach(this.cwd);
26
- test_utils_1.assert.isEqualDeep(mercury_client_1.MercuryTestClient.getNamespacesThatMustBeHandledLocally(), [skill.slug]);
27
- }
28
- };
29
- __decorate([
30
- (0, test_utils_1.test)()
31
- ], MakingSureLocalEventsAreHandledLocallyTest, "throwsWhenNoListenerSetForLocalEvent", null);
32
- MakingSureLocalEventsAreHandledLocallyTest = __decorate([
33
- (0, login_1.default)(constants_1.DEMO_NUMBER_HANDLING_EVENTS_LOCALLY)
34
- ], MakingSureLocalEventsAreHandledLocallyTest);
35
- exports.default = MakingSureLocalEventsAreHandledLocallyTest;
@@ -1,20 +0,0 @@
1
- import AbstractSpruceFixtureTest from '../../tests/AbstractSpruceFixtureTest';
2
- export default class MercuryFixtureTest extends AbstractSpruceFixtureTest {
3
- private static fixture;
4
- protected static beforeEach(): Promise<void>;
5
- protected static hasDefaultContractByDefault(): Promise<void>;
6
- protected static canGetMoreThanOneClient(): Promise<void>;
7
- protected static canCreateMercuryFixture(): Promise<void>;
8
- protected static returnsConnectedClient(): Promise<void>;
9
- protected static returnsSameClientOnSecondConnect(): Promise<void>;
10
- protected static importsContractIfLocalOneIsGenerated(sigs: any[]): Promise<void>;
11
- protected static beforeEachResetsBackToSavedContract(): Promise<void>;
12
- protected static typesTestProperly(): Promise<void>;
13
- protected static canSetDefaultClient(): Promise<void>;
14
- protected static allClientsGoingForwardUseThatClient(): Promise<void>;
15
- protected static resetsDefaultClientBeforeEach(): Promise<void>;
16
- protected static canForceNewClient(): Promise<void>;
17
- protected static setsRequiresLocalListenersByDefault(): Promise<void>;
18
- private static connectToApi;
19
- private static createDirWriteContractFileAndSetCwd;
20
- }
@@ -1,187 +0,0 @@
1
- "use strict";
2
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
- return c > 3 && r && Object.defineProperty(target, key, r), r;
7
- };
8
- var __importDefault = (this && this.__importDefault) || function (mod) {
9
- return (mod && mod.__esModule) ? mod : { "default": mod };
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const mercury_client_1 = require("@sprucelabs/mercury-client");
13
- const mercury_core_events_1 = require("@sprucelabs/mercury-core-events");
14
- const spruce_event_utils_1 = require("@sprucelabs/spruce-event-utils");
15
- const spruce_skill_utils_1 = require("@sprucelabs/spruce-skill-utils");
16
- const test_utils_1 = require("@sprucelabs/test-utils");
17
- const AbstractSpruceFixtureTest_1 = __importDefault(require("../../tests/AbstractSpruceFixtureTest"));
18
- const FixtureFactory_1 = __importDefault(require("../../tests/fixtures/FixtureFactory"));
19
- const MercuryFixture_1 = __importDefault(require("../../tests/fixtures/MercuryFixture"));
20
- class MercuryFixtureTest extends AbstractSpruceFixtureTest_1.default {
21
- static async beforeEach() {
22
- await super.beforeEach();
23
- this.fixture = this.Fixture('mercury');
24
- }
25
- static async hasDefaultContractByDefault() {
26
- const client = await this.fixture.connectToApi();
27
- //@ts-ignore
28
- test_utils_1.assert.isTruthy(client.eventContract);
29
- const mixed = spruce_event_utils_1.eventContractUtil.unifyContracts([
30
- mercury_core_events_1.coreEventContracts[0],
31
- mercury_client_1.connectionStatusContract,
32
- ]);
33
- test_utils_1.assert.doesInclude(
34
- //@ts-ignore
35
- client.eventContract, mixed);
36
- }
37
- static async canGetMoreThanOneClient() {
38
- await this.fixture.connectToApi({ shouldReUseClient: false });
39
- await this.fixture.connectToApi({ shouldReUseClient: false });
40
- }
41
- static async canCreateMercuryFixture() {
42
- test_utils_1.assert.isTruthy(this.fixture);
43
- }
44
- static async returnsConnectedClient() {
45
- const client = await this.fixture.connectToApi();
46
- test_utils_1.assert.isTrue(client.isConnected());
47
- await client.disconnect();
48
- }
49
- static async returnsSameClientOnSecondConnect() {
50
- const client = await this.fixture.connectToApi();
51
- //@ts-ignore
52
- client.__monkeyPatch = true;
53
- const client2 = await this.fixture.connectToApi();
54
- //@ts-ignore
55
- test_utils_1.assert.isTrue(client2.__monkeyPatch);
56
- await client.disconnect();
57
- test_utils_1.assert.isFalse(client2.isConnected());
58
- }
59
- static async importsContractIfLocalOneIsGenerated(sigs) {
60
- this.createDirWriteContractFileAndSetCwd(sigs);
61
- const client = await this.connectToApi();
62
- //@ts-ignore
63
- test_utils_1.assert.isTruthy(client.eventContract);
64
- test_utils_1.assert.doesInclude(
65
- //@ts-ignore
66
- client.eventContract.eventSignatures, sigs[0].eventSignatures);
67
- spruce_event_utils_1.eventContractUtil.getSignatureByName(
68
- //@ts-ignore
69
- client.eventContract, 'add-role::v2020_12_25');
70
- }
71
- static async beforeEachResetsBackToSavedContract() {
72
- this.createDirWriteContractFileAndSetCwd([
73
- {
74
- eventSignatures: {
75
- ['new-event']: true,
76
- },
77
- },
78
- ]);
79
- const client = (await this.connectToApi());
80
- await MercuryFixture_1.default.beforeEach(this.cwd);
81
- await client.on('new-event', () => { });
82
- }
83
- static async typesTestProperly() {
84
- const test = () => {
85
- return {};
86
- };
87
- const value = test();
88
- test_utils_1.assert.isTruthy(value);
89
- }
90
- static async canSetDefaultClient() {
91
- test_utils_1.assert.isFunction(MercuryFixture_1.default.setDefaultClient);
92
- const client = await this.connectToApi();
93
- MercuryFixture_1.default.setDefaultClient(client);
94
- test_utils_1.assert.isEqual(MercuryFixture_1.default.getDefaultClient(), client);
95
- }
96
- static async allClientsGoingForwardUseThatClient() {
97
- const client = await this.connectToApi();
98
- MercuryFixture_1.default.setDefaultClient(client);
99
- const client2 = await this.connectToApi();
100
- test_utils_1.assert.isEqual(client, client2);
101
- }
102
- static async resetsDefaultClientBeforeEach() {
103
- const client = await this.connectToApi();
104
- MercuryFixture_1.default.setDefaultClient(client);
105
- await MercuryFixture_1.default.beforeEach(this.cwd);
106
- const client2 = await this.connectToApi();
107
- test_utils_1.assert.isNotEqual(client, client2);
108
- }
109
- static async canForceNewClient() {
110
- const client = await this.connectToApi();
111
- MercuryFixture_1.default.setDefaultClient(client);
112
- const client2 = await this.Fixture('mercury').connectToApi({
113
- shouldReUseClient: false,
114
- });
115
- test_utils_1.assert.isNotEqual(client, client2);
116
- }
117
- static async setsRequiresLocalListenersByDefault() {
118
- test_utils_1.assert.isTrue(mercury_client_1.MercuryTestClient.getShouldRequireLocalListeners());
119
- }
120
- static async connectToApi(options) {
121
- return await new FixtureFactory_1.default({ cwd: this.cwd })
122
- .Fixture('mercury')
123
- .connectToApi(options);
124
- }
125
- static createDirWriteContractFileAndSetCwd(sigs) {
126
- this.cwd = spruce_skill_utils_1.diskUtil.createRandomTempDir();
127
- const destination = spruce_skill_utils_1.diskUtil.resolvePath(this.cwd, spruce_skill_utils_1.HASH_SPRUCE_BUILD_DIR, 'events/events.contract.js');
128
- const contents = `exports["default"] = ${JSON.stringify([
129
- ...mercury_core_events_1.coreEventContracts,
130
- ...sigs,
131
- ])};`;
132
- spruce_skill_utils_1.diskUtil.writeFile(destination, contents);
133
- }
134
- }
135
- exports.default = MercuryFixtureTest;
136
- __decorate([
137
- (0, test_utils_1.test)()
138
- ], MercuryFixtureTest, "hasDefaultContractByDefault", null);
139
- __decorate([
140
- (0, test_utils_1.test)()
141
- ], MercuryFixtureTest, "canGetMoreThanOneClient", null);
142
- __decorate([
143
- (0, test_utils_1.test)()
144
- ], MercuryFixtureTest, "canCreateMercuryFixture", null);
145
- __decorate([
146
- (0, test_utils_1.test)()
147
- ], MercuryFixtureTest, "returnsConnectedClient", null);
148
- __decorate([
149
- (0, test_utils_1.test)()
150
- ], MercuryFixtureTest, "returnsSameClientOnSecondConnect", null);
151
- __decorate([
152
- (0, test_utils_1.test)('auto imports signature 1', [
153
- {
154
- eventSignatures: {
155
- ['taco-bravo']: true,
156
- },
157
- },
158
- ]),
159
- (0, test_utils_1.test)('auto imports signature 2', [
160
- {
161
- eventSignatures: {
162
- ['taco-bravo2']: true,
163
- },
164
- },
165
- ])
166
- ], MercuryFixtureTest, "importsContractIfLocalOneIsGenerated", null);
167
- __decorate([
168
- (0, test_utils_1.test)()
169
- ], MercuryFixtureTest, "beforeEachResetsBackToSavedContract", null);
170
- __decorate([
171
- (0, test_utils_1.test)()
172
- ], MercuryFixtureTest, "typesTestProperly", null);
173
- __decorate([
174
- (0, test_utils_1.test)()
175
- ], MercuryFixtureTest, "canSetDefaultClient", null);
176
- __decorate([
177
- (0, test_utils_1.test)()
178
- ], MercuryFixtureTest, "allClientsGoingForwardUseThatClient", null);
179
- __decorate([
180
- (0, test_utils_1.test)()
181
- ], MercuryFixtureTest, "resetsDefaultClientBeforeEach", null);
182
- __decorate([
183
- (0, test_utils_1.test)()
184
- ], MercuryFixtureTest, "canForceNewClient", null);
185
- __decorate([
186
- (0, test_utils_1.test)()
187
- ], MercuryFixtureTest, "setsRequiresLocalListenersByDefault", null);
@@ -1,31 +0,0 @@
1
- import AbstractSpruceFixtureTest from '../../tests/AbstractSpruceFixtureTest';
2
- import { RoleBase } from '../../types/fixture.types';
3
- export default class OrganizationFixtureTest extends AbstractSpruceFixtureTest {
4
- protected static canCreateOrganizationFixture(): Promise<void>;
5
- protected static canSeedOrg(): Promise<void>;
6
- protected static orgFixtureDestroysOrgs(): Promise<void>;
7
- protected static isNotPartOfOrgtoStart(): Promise<void>;
8
- protected static updatingBadOrgTHrows(): Promise<void>;
9
- protected static canUpdateOrg(): Promise<void>;
10
- protected static canUpdateOrgAddress(): Promise<void>;
11
- protected static canMakeOrgPublicAndPrivate(): Promise<void>;
12
- protected static canAddPersonToOrg(base: RoleBase): Promise<void>;
13
- private static isPersonPartOfOrg;
14
- protected static isNotInstalledByDefault(): Promise<void>;
15
- protected static showsAsInstalled(): Promise<void>;
16
- protected static cantInstallWithBadSkill(): Promise<void>;
17
- protected static canInstallWithSlug(): Promise<void>;
18
- protected static canInstallSkillFromAnotherPerson(): Promise<void>;
19
- protected static canDeleteAllExistingOrgs(): Promise<void>;
20
- protected static passesThroughAllFieldsToRequest(): Promise<void>;
21
- protected static canPassPersonFixture(): void;
22
- protected static canSeedOrgWithNoOptions(): Promise<void>;
23
- protected static removePersonThrowsWithBadIds(): Promise<void>;
24
- protected static canRemovePersonFromOrg(roleBase: RoleBase): Promise<void>;
25
- private static Org;
26
- private static seedOrgAndHirePerson;
27
- private static assertSkillIsInstalled;
28
- private static seedOrgAndSkill;
29
- private static assertOrgIsPublicValue;
30
- private static setAndAssertOrgIsPublic;
31
- }