You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- name: dataGatherState cannot transition from Running to Pending
378
-
initial: |
379
-
apiVersion: insights.openshift.io/v1alpha2
380
-
kind: DataGather
381
-
spec: {} # No spec is required for a DataGather
382
-
status:
383
-
dataGatherState: Running
384
-
updated: |
385
-
apiVersion: insights.openshift.io/v1alpha2
386
-
kind: DataGather
387
-
spec: {} # No spec is required for a DataGather
388
-
status:
389
-
dataGatherState: Pending
390
-
expectedStatusError: 'status.dataGatherState: Invalid value: "string": dataGatherState cannot transition from Running to Pending'
391
-
- name: dataGatherState cannot transition from Completed to Pending
392
-
initial: |
393
-
apiVersion: insights.openshift.io/v1alpha2
394
-
kind: DataGather
395
-
spec: {} # No spec is required for a DataGather
396
-
status:
397
-
dataGatherState: Completed
398
-
updated: |
399
-
apiVersion: insights.openshift.io/v1alpha2
400
-
kind: DataGather
401
-
spec: {} # No spec is required for a DataGather
402
-
status:
403
-
dataGatherState: Pending
404
-
expectedStatusError: 'status.dataGatherState: Invalid value: "string": dataGatherState cannot transition from Completed to Pending'
405
-
- name: dataGatherState cannot transition from Failed to Pending
406
-
initial: |
407
-
apiVersion: insights.openshift.io/v1alpha2
408
-
kind: DataGather
409
-
spec: {} # No spec is required for a DataGather
410
-
status:
411
-
dataGatherState: Failed
412
-
updated: |
413
-
apiVersion: insights.openshift.io/v1alpha2
414
-
kind: DataGather
415
-
spec: {} # No spec is required for a DataGather
416
-
status:
417
-
dataGatherState: Pending
418
-
expectedStatusError: 'status.dataGatherState: Invalid value: "string": dataGatherState cannot transition from Failed to Pending'
419
-
- name: dataGatherState cannot transition from Completed to Running
420
-
initial: |
421
-
apiVersion: insights.openshift.io/v1alpha2
422
-
kind: DataGather
423
-
spec: {} # No spec is required for a DataGather
424
-
status:
425
-
dataGatherState: Completed
426
-
updated: |
427
-
apiVersion: insights.openshift.io/v1alpha2
428
-
kind: DataGather
429
-
spec: {} # No spec is required for a DataGather
430
-
status:
431
-
dataGatherState: Running
432
-
expectedStatusError: 'status.dataGatherState: Invalid value: "string": dataGatherState cannot transition from Completed to Running'
433
-
- name: dataGatherState cannot transition from Failed to Running
434
-
initial: |
435
-
apiVersion: insights.openshift.io/v1alpha2
436
-
kind: DataGather
437
-
spec: {} # No spec is required for a DataGather
438
-
status:
439
-
dataGatherState: Failed
440
-
updated: |
441
-
apiVersion: insights.openshift.io/v1alpha2
442
-
kind: DataGather
443
-
spec: {} # No spec is required for a DataGather
444
-
status:
445
-
dataGatherState: Running
446
-
expectedStatusError: 'status.dataGatherState: Invalid value: "string": dataGatherState cannot transition from Failed to Running'
447
-
- name: lastGatherDuration can be updated with a trailing zero value
359
+
- name: lastGatherSeconds must be integer
448
360
initial: |
449
361
apiVersion: insights.openshift.io/v1alpha2
450
362
kind: DataGather
@@ -456,28 +368,35 @@ tests:
456
368
status:
457
369
gatherers:
458
370
- name: testGatherer
459
-
lastGatherDuration: 1m0s
371
+
lastGatherSeconds: 1.1
460
372
conditions:
461
373
- type: Gathered
462
374
status: "True"
463
375
reason: OK
464
376
message: "test message"
465
377
lastTransitionTime: "2024-12-01T08:04:21Z"
466
-
expected: |
378
+
expectedStatusError: "gatherers[0].lastGatherSeconds in body must be of type integer"
379
+
- name: lastGatherSeconds cannot be updated with an invalid value
380
+
initial: |
381
+
apiVersion: insights.openshift.io/v1alpha2
382
+
kind: DataGather
383
+
spec: {} # No spec is required for a DataGather
384
+
updated: |
467
385
apiVersion: insights.openshift.io/v1alpha2
468
386
kind: DataGather
469
387
spec: {} # No spec is required for a DataGather
470
388
status:
471
389
gatherers:
472
390
- name: testGatherer
473
-
lastGatherDuration: 1m0s
391
+
lastGatherSeconds: 1d2h
474
392
conditions:
475
393
- type: Gathered
476
394
status: "True"
477
395
reason: OK
478
396
message: "test message"
479
397
lastTransitionTime: "2024-12-01T08:04:21Z"
480
-
- name: lastGatherDuration can be updated with a leading zero value
398
+
expectedStatusError: 'Invalid value: "string": gatherers[0].lastGatherSeconds in body must be of type integer'
399
+
- name: lastGatherSeconds cannot be updated with a negative value
481
400
initial: |
482
401
apiVersion: insights.openshift.io/v1alpha2
483
402
kind: DataGather
@@ -489,28 +408,28 @@ tests:
489
408
status:
490
409
gatherers:
491
410
- name: testGatherer
492
-
lastGatherDuration: 0m11s
411
+
lastGatherSeconds: -5
493
412
conditions:
494
413
- type: Gathered
495
414
status: "True"
496
415
reason: OK
497
416
message: "test message"
498
417
lastTransitionTime: "2024-12-01T08:04:21Z"
499
-
expected: |
418
+
expectedStatusError: "lastGatherSeconds in body should be greater than or equal to 0"
419
+
- name: should not be updated with URL that is not HTTPS
420
+
initial: |
421
+
apiVersion: insights.openshift.io/v1alpha2
422
+
kind: DataGather
423
+
spec: {} # No spec is required for a DataGather
424
+
updated: |
500
425
apiVersion: insights.openshift.io/v1alpha2
501
426
kind: DataGather
502
427
spec: {} # No spec is required for a DataGather
503
428
status:
504
-
gatherers:
505
-
- name: testGatherer
506
-
lastGatherDuration: 0m11s
507
-
conditions:
508
-
- type: Gathered
509
-
status: "True"
510
-
reason: OK
511
-
message: "test message"
512
-
lastTransitionTime: "2024-12-01T08:04:21Z"
513
-
- name: lastGatherDuration can be updated with a decimal number value
429
+
insightsReport:
430
+
uri: http://example.com
431
+
expectedStatusError: 'status.insightsReport.uri: Invalid value: "string": URI must be a valid HTTPS URL (e.g., https://example.com)'
432
+
- name: should be updated with a valid HTTPS URL
514
433
initial: |
515
434
apiVersion: insights.openshift.io/v1alpha2
516
435
kind: DataGather
@@ -520,30 +439,16 @@ tests:
520
439
kind: DataGather
521
440
spec: {} # No spec is required for a DataGather
522
441
status:
523
-
gatherers:
524
-
- name: testGatherer
525
-
lastGatherDuration: 1m0.77s
526
-
conditions:
527
-
- type: Gathered
528
-
status: "True"
529
-
reason: OK
530
-
message: "test message"
531
-
lastTransitionTime: "2024-12-01T08:04:21Z"
442
+
insightsReport:
443
+
uri: https://example.com
532
444
expected: |
533
445
apiVersion: insights.openshift.io/v1alpha2
534
446
kind: DataGather
535
447
spec: {} # No spec is required for a DataGather
536
448
status:
537
-
gatherers:
538
-
- name: testGatherer
539
-
lastGatherDuration: 1m0.77s
540
-
conditions:
541
-
- type: Gathered
542
-
status: "True"
543
-
reason: OK
544
-
message: "test message"
545
-
lastTransitionTime: "2024-12-01T08:04:21Z"
546
-
- name: lastGatherDuration cannot be updated with an invalid value
449
+
insightsReport:
450
+
uri: https://example.com
451
+
- name: should be updated with a valid totalRisk
547
452
initial: |
548
453
apiVersion: insights.openshift.io/v1alpha2
549
454
kind: DataGather
@@ -553,37 +458,22 @@ tests:
553
458
kind: DataGather
554
459
spec: {} # No spec is required for a DataGather
555
460
status:
556
-
gatherers:
557
-
- name: testGatherer
558
-
lastGatherDuration: 1d2h
559
-
conditions:
560
-
- type: Gathered
561
-
status: "True"
562
-
reason: OK
563
-
message: "test message"
564
-
lastTransitionTime: "2024-12-01T08:04:21Z"
565
-
expectedStatusError: "Invalid value: \"1d2h\": gatherers[0].lastGatherDuration in body should match '^(([0-9]+(?:\\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$'"
566
-
- name: lastGatherDuration cannot be updated with a negative value
567
-
initial: |
568
-
apiVersion: insights.openshift.io/v1alpha2
569
-
kind: DataGather
570
-
spec: {} # No spec is required for a DataGather
571
-
updated: |
461
+
insightsReport:
462
+
healthChecks:
463
+
- description: Low risk update test
464
+
totalRisk: Low
465
+
advisorURI: https://example.com
466
+
expected: |
572
467
apiVersion: insights.openshift.io/v1alpha2
573
468
kind: DataGather
574
469
spec: {} # No spec is required for a DataGather
575
470
status:
576
-
gatherers:
577
-
- name: testGatherer
578
-
lastGatherDuration: -0m5s
579
-
conditions:
580
-
- type: Gathered
581
-
status: "True"
582
-
reason: OK
583
-
message: "test message"
584
-
lastTransitionTime: "2024-12-01T08:04:21Z"
585
-
expectedStatusError: "Invalid value: \"-0m5s\": gatherers[0].lastGatherDuration in body should match '^(([0-9]+(?:\\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$'"
586
-
- name: should not be updated with URL that is not HTTPS
471
+
insightsReport:
472
+
healthChecks:
473
+
- description: Low risk update test
474
+
totalRisk: Low
475
+
advisorURI: https://example.com
476
+
- name: should not be updated with invalid totalRisk value
587
477
initial: |
588
478
apiVersion: insights.openshift.io/v1alpha2
589
479
kind: DataGather
@@ -594,9 +484,12 @@ tests:
594
484
spec: {} # No spec is required for a DataGather
595
485
status:
596
486
insightsReport:
597
-
uri: http://example.com
598
-
expectedStatusError: 'status.insightsReport.uri: Invalid value: "string": URI must be a valid HTTPS URL (e.g., https://example.com)'
0 commit comments