apiTokens.spec.jsx.snap 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196
  1. // Jest Snapshot v1, https://goo.gl/fbAQLP
  2. exports[`ApiTokens renders empty result 1`] = `
  3. <SideEffect(DocumentTitle)
  4. title="API Tokens - Sentry"
  5. >
  6. <div>
  7. <SettingsPageHeading
  8. action={
  9. <Button
  10. className="ref-create-token"
  11. disabled={false}
  12. priority="primary"
  13. size="small"
  14. to="/settings/account/api/auth-tokens/new-token/"
  15. >
  16. Create New Token
  17. </Button>
  18. }
  19. noTitleStyles={false}
  20. title="Auth Tokens"
  21. />
  22. <TextBlock>
  23. Authentication tokens allow you to perform actions against the Sentry API on behalf of your account. They're the easiest way to get started using the API.
  24. </TextBlock>
  25. <TextBlock>
  26. <span
  27. key="5"
  28. >
  29. <span
  30. key="0"
  31. >
  32. For more information on how to use the web API, see our
  33. </span>
  34. <a
  35. href="https://docs.sentry.io/hosted/api/"
  36. key="2"
  37. >
  38. <span
  39. key="1"
  40. >
  41. documentation
  42. </span>
  43. </a>
  44. <span
  45. key="3"
  46. >
  47. .
  48. </span>
  49. </span>
  50. </TextBlock>
  51. <TextBlock>
  52. <small>
  53. psst. Looking for the
  54. <strong>
  55. DSN
  56. </strong>
  57. for an SDK? You'll find that under
  58. <strong>
  59. [Project] » Settings » Client Keys
  60. </strong>
  61. .
  62. </small>
  63. </TextBlock>
  64. <Panel>
  65. <PanelHeader
  66. disablePadding={true}
  67. >
  68. <Flex
  69. align="center"
  70. >
  71. <Box
  72. flex="1"
  73. px={2}
  74. >
  75. Auth Token
  76. </Box>
  77. </Flex>
  78. </PanelHeader>
  79. <PanelBody
  80. direction="column"
  81. disablePadding={true}
  82. flex={false}
  83. >
  84. <EmptyMessage>
  85. You haven't created any authentication tokens yet.
  86. </EmptyMessage>
  87. </PanelBody>
  88. </Panel>
  89. </div>
  90. </SideEffect(DocumentTitle)>
  91. `;
  92. exports[`ApiTokens renders with result 1`] = `
  93. <SideEffect(DocumentTitle)
  94. title="API Tokens - Sentry"
  95. >
  96. <div>
  97. <SettingsPageHeading
  98. action={
  99. <Button
  100. className="ref-create-token"
  101. disabled={false}
  102. priority="primary"
  103. size="small"
  104. to="/settings/account/api/auth-tokens/new-token/"
  105. >
  106. Create New Token
  107. </Button>
  108. }
  109. noTitleStyles={false}
  110. title="Auth Tokens"
  111. />
  112. <TextBlock>
  113. Authentication tokens allow you to perform actions against the Sentry API on behalf of your account. They're the easiest way to get started using the API.
  114. </TextBlock>
  115. <TextBlock>
  116. <span
  117. key="5"
  118. >
  119. <span
  120. key="0"
  121. >
  122. For more information on how to use the web API, see our
  123. </span>
  124. <a
  125. href="https://docs.sentry.io/hosted/api/"
  126. key="2"
  127. >
  128. <span
  129. key="1"
  130. >
  131. documentation
  132. </span>
  133. </a>
  134. <span
  135. key="3"
  136. >
  137. .
  138. </span>
  139. </span>
  140. </TextBlock>
  141. <TextBlock>
  142. <small>
  143. psst. Looking for the
  144. <strong>
  145. DSN
  146. </strong>
  147. for an SDK? You'll find that under
  148. <strong>
  149. [Project] » Settings » Client Keys
  150. </strong>
  151. .
  152. </small>
  153. </TextBlock>
  154. <Panel>
  155. <PanelHeader
  156. disablePadding={true}
  157. >
  158. <Flex
  159. align="center"
  160. >
  161. <Box
  162. flex="1"
  163. px={2}
  164. >
  165. Auth Token
  166. </Box>
  167. </Flex>
  168. </PanelHeader>
  169. <PanelBody
  170. direction="column"
  171. disablePadding={true}
  172. flex={false}
  173. >
  174. <ApiTokenRow
  175. key="apitoken123"
  176. onRemove={[Function]}
  177. token={
  178. Object {
  179. "dateCreated": 2018-01-12T02:01:41.000Z,
  180. "scopes": Array [
  181. "scope1",
  182. "scope2",
  183. ],
  184. "token": "apitoken123",
  185. }
  186. }
  187. />
  188. </PanelBody>
  189. </Panel>
  190. </div>
  191. </SideEffect(DocumentTitle)>
  192. `;