@@ -112,18 +112,9 @@ describe('flows alert panel', () => {
112112 'r._notebook_link'
113113 )
114114
115- // make sure task export contains notebook link
116- cy . getByTestID ( 'task-form-save' ) . click ( )
117- cy . getByTestID ( 'overlay--body' ) . should ( 'be.visible' )
118- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
119- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
120- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
121- cy . url ( ) . then ( url => {
122- cy . getByTestID ( 'flux-editor' ) . contains (
123- `|> set(key: "_notebook_link", value: "${ url } ")`
124- )
125- } )
126- } )
115+ // NOTE: we need to verify that the generated task flux contains
116+ // `|> set(key: "_notebook_link", value: "${url}")`
117+ // but we dont currently redirect to the task editor anymore
127118 } )
128119
129120 it ( 'should build alert for each endpoint' , ( ) => {
@@ -192,7 +183,6 @@ describe('flows alert panel', () => {
192183
193184 const fakeEmail = 'super@fake.com'
194185 const fakeUrl = 'super-fake.com'
195- const fakeSecretFlux = 'secrets.get(key: "mySecret")'
196186 const fakeChannel = 'fake-channel'
197187
198188 // === AWS SES ===
@@ -213,19 +203,11 @@ describe('flows alert panel', () => {
213203 cy . getByTestID ( 'dropdown-item--mySecret' ) . click ( )
214204 cy . getByTestID ( 'input--email' ) . type ( fakeEmail )
215205
216- // make sure task export contains the fields
217206 cy . getByTestID ( 'task-form-save' ) . click ( )
218- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
219- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
220- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
221- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
222- cy . getByTestID ( 'flux-editor' ) . contains ( fakeUrl )
223- cy . getByTestID ( 'flux-editor' ) . contains ( fakeSecretFlux )
224- cy . getByTestID ( 'flux-editor' ) . contains ( fakeEmail )
225- } )
226-
227- // close popup
228- cy . get ( '.cf-overlay--dismiss' ) . click ( )
207+ /* NOTE: we used to be able to test that the generated flux contained the the
208+ * selected values, but that mechanism has been removed from the product
209+ * we should add back that ability here
210+ */
229211
230212 // === HTTP ===
231213
@@ -236,18 +218,11 @@ describe('flows alert panel', () => {
236218 cy . getByTestID ( 'input--url' ) . type ( fakeUrl )
237219 cy . getByTestID ( 'input--token' ) . type ( 'fake-token' )
238220
239- // make sure task export contains the fields
240221 cy . getByTestID ( 'task-form-save' ) . click ( )
241- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
242- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
243- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
244- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
245- cy . getByTestID ( 'flux-editor' ) . contains ( fakeUrl )
246- cy . getByTestID ( 'flux-editor' ) . contains ( 'fake-token' )
247- } )
248-
249- // close popup
250- cy . get ( '.cf-overlay--dismiss' ) . click ( )
222+ /* NOTE: we used to be able to test that the generated flux contained the the
223+ * selected values, but that mechanism has been removed from the product
224+ * we should add back that ability here
225+ */
251226
252227 // === MAILGUN ===
253228 const mailgunDomain = 'fake.com'
@@ -259,19 +234,11 @@ describe('flows alert panel', () => {
259234 cy . getByTestID ( 'dropdown-item--mySecret' ) . click ( )
260235 cy . getByTestID ( 'input--email' ) . type ( fakeEmail )
261236
262- // make sure task export contains the fields
263237 cy . getByTestID ( 'task-form-save' ) . click ( )
264- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
265- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
266- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
267- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
268- cy . getByTestID ( 'flux-editor' ) . contains ( mailgunDomain )
269- cy . getByTestID ( 'flux-editor' ) . contains ( fakeSecretFlux )
270- cy . getByTestID ( 'flux-editor' ) . contains ( fakeEmail )
271- } )
272-
273- // close popup
274- cy . get ( '.cf-overlay--dismiss' ) . click ( )
238+ /* NOTE: we used to be able to test that the generated flux contained the the
239+ * selected values, but that mechanism has been removed from the product
240+ * we should add back that ability here
241+ */
275242
276243 // === MAILJET ===
277244
@@ -283,18 +250,11 @@ describe('flows alert panel', () => {
283250 cy . getByTestID ( 'dropdown-item--mySecret' ) . click ( )
284251 cy . getByTestID ( 'input--email' ) . type ( fakeEmail )
285252
286- // make sure task export contains the fields
287253 cy . getByTestID ( 'task-form-save' ) . click ( )
288- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
289- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
290- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
291- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
292- cy . getByTestID ( 'flux-editor' ) . contains ( fakeEmail )
293- cy . getByTestID ( 'flux-editor' ) . contains ( fakeSecretFlux )
294- } )
295-
296- // close popup
297- cy . get ( '.cf-overlay--dismiss' ) . click ( )
254+ /* NOTE: we used to be able to test that the generated flux contained the the
255+ * selected values, but that mechanism has been removed from the product
256+ * we should add back that ability here
257+ */
298258
299259 // === PAGERDUTY ===
300260 const pagerDutyRoutingKey = 'fake-key'
@@ -304,18 +264,11 @@ describe('flows alert panel', () => {
304264 cy . getByTestID ( 'input--url' ) . type ( fakeUrl )
305265 cy . getByTestID ( 'input--key' ) . type ( pagerDutyRoutingKey )
306266
307- // make sure task export contains the fields
308267 cy . getByTestID ( 'task-form-save' ) . click ( )
309- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
310- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
311- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
312- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
313- cy . getByTestID ( 'flux-editor' ) . contains ( fakeUrl )
314- cy . getByTestID ( 'flux-editor' ) . contains ( pagerDutyRoutingKey )
315- } )
316-
317- // close popup
318- cy . get ( '.cf-overlay--dismiss' ) . click ( )
268+ /* NOTE: we used to be able to test that the generated flux contained the the
269+ * selected values, but that mechanism has been removed from the product
270+ * we should add back that ability here
271+ */
319272
320273 // === SENDGRID ===
321274
@@ -325,44 +278,26 @@ describe('flows alert panel', () => {
325278 cy . getByTestID ( 'dropdown--apiKey' ) . click ( )
326279 cy . getByTestID ( 'dropdown-item--mySecret' ) . click ( )
327280
328- // make sure task export contains the fields
329281 cy . getByTestID ( 'task-form-save' ) . click ( )
330- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
331- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
332- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
333- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
334- cy . getByTestID ( 'flux-editor' ) . contains ( fakeEmail )
335- cy . getByTestID ( 'flux-editor' ) . contains ( fakeSecretFlux )
336- } )
337-
338- // close popup
339- cy . get ( '.cf-overlay--dismiss' ) . click ( )
282+ /* NOTE: we used to be able to test that the generated flux contained the the
283+ * selected values, but that mechanism has been removed from the product
284+ * we should add back that ability here
285+ */
340286
341287 // === SLACK ===
342- const slackColor = '#34BB55'
343288
344289 // complete fields
345290 cy . getByTestID ( 'dropdown-item--slack' ) . click ( )
346291 cy . getByTestID ( 'input--url' ) . type ( fakeUrl )
347292 cy . getByTestID ( 'input--channel' ) . type ( fakeChannel )
348293
349- // make sure task export contains the fields
350294 cy . getByTestID ( 'task-form-save' ) . click ( )
351- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
352- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
353- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
354- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
355- cy . getByTestID ( 'flux-editor' ) . contains ( fakeUrl )
356- cy . getByTestID ( 'flux-editor' ) . contains ( fakeChannel )
357- cy . getByTestID ( 'flux-editor' ) . contains ( slackColor )
358- } )
359-
360- // close popup
361- cy . get ( '.cf-overlay--dismiss' ) . click ( )
295+ /* NOTE: we used to be able to test that the generated flux contained the the
296+ * selected values, but that mechanism has been removed from the product
297+ * we should add back that ability here
298+ */
362299
363300 // === TELEGRAM ===
364- const parseMode = 'MarkdownV2'
365- const telegramURL = 'https://api.telegram.org/bot'
366301
367302 // complete fields
368303 cy . getByTestID ( 'dropdown-item--telegram' ) . click ( )
@@ -376,22 +311,11 @@ describe('flows alert panel', () => {
376311 cy . getByTestID ( 'variable-form-save' ) . click ( )
377312 cy . getByTestID ( 'dropdown-button--token' ) . contains ( 'an apple a day' )
378313
379- // make sure task export contains the fields
380314 cy . getByTestID ( 'task-form-save' ) . click ( )
381- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
382- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
383- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
384- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
385- cy . getByTestID ( 'flux-editor' ) . contains ( telegramURL )
386- cy . getByTestID ( 'flux-editor' ) . contains ( fakeChannel )
387- cy . getByTestID ( 'flux-editor' ) . contains (
388- 'secrets.get(key: "an apple a day")'
389- )
390- cy . getByTestID ( 'flux-editor' ) . contains ( parseMode )
391- } )
392-
393- // close popup
394- cy . get ( '.cf-overlay--dismiss' ) . click ( )
315+ /* NOTE: we used to be able to test that the generated flux contained the the
316+ * selected values, but that mechanism has been removed from the product
317+ * we should add back that ability here
318+ */
395319
396320 // === ZENOSS ===
397321 const zenossAction = 'my-action'
@@ -409,20 +333,10 @@ describe('flows alert panel', () => {
409333 cy . getByTestID ( 'input--action' ) . type ( zenossAction )
410334 cy . getByTestID ( 'input--method' ) . type ( zenossMethod )
411335
412- // make sure task export contains the fields
413336 cy . getByTestID ( 'task-form-save' ) . click ( )
414- cy . getByTestID ( 'export-as-overlay--header' ) . should ( 'be.visible' )
415- cy . getByTestID ( 'flux-editor' ) . should ( 'exist' )
416- cy . getByTestID ( 'form--footer' ) . scrollIntoView ( )
417- cy . getByTestID ( 'overlay--body' ) . within ( ( ) => {
418- cy . getByTestID ( 'flux-editor' ) . contains ( fakeUrl )
419- cy . getByTestID ( 'flux-editor' ) . contains ( fakeSecretFlux )
420- cy . getByTestID ( 'flux-editor' ) . contains ( zenossMethod )
421- cy . getByTestID ( 'flux-editor' ) . contains ( zenossAction )
422- cy . getByTestID ( 'flux-editor' ) . contains ( 'Critical' )
423- } )
424-
425- // close popup
426- cy . get ( '.cf-overlay--dismiss' ) . click ( )
337+ /* NOTE: we used to be able to test that the generated flux contained the the
338+ * selected values, but that mechanism has been removed from the product
339+ * we should add back that ability here
340+ */
427341 } )
428342} )
0 commit comments