mirror of
https://github.com/truenas/charts.git
synced 2026-06-17 07:27:44 +08:00
fix some tests
This commit is contained in:
@@ -25,8 +25,8 @@ tests:
|
||||
updateStrategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 0
|
||||
maxUnavailable: 1
|
||||
maxSurge: 1
|
||||
|
||||
- it: should apply defaults to rollingUpdate
|
||||
set:
|
||||
@@ -46,7 +46,7 @@ tests:
|
||||
content:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 1
|
||||
maxSurge: 0
|
||||
maxUnavailable: 1
|
||||
|
||||
- it: should apply spec correctly
|
||||
|
||||
@@ -28,3 +28,22 @@ tests:
|
||||
asserts:
|
||||
- failedTemplate:
|
||||
errorMessage: DaemonSet - Expected <rollingUpdate> to be a dictionary, but got [string]
|
||||
|
||||
- it: should fail with both maxSurge and maxUnavailable set to 0
|
||||
set:
|
||||
fallbackDefaults:
|
||||
maxSurge: 0
|
||||
maxUnavailable: 0
|
||||
workload:
|
||||
workload-name:
|
||||
enabled: true
|
||||
primary: true
|
||||
type: DaemonSet
|
||||
strategy: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 0
|
||||
maxUnavailable: 0
|
||||
podSpec: {}
|
||||
asserts:
|
||||
- failedTemplate:
|
||||
errorMessage: DaemonSet - Cannot have <maxSurge> and <maxUnavailable> both set to 0
|
||||
|
||||
@@ -44,7 +44,7 @@ tests:
|
||||
content:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 1
|
||||
maxSurge: 0
|
||||
maxUnavailable: 1
|
||||
|
||||
- it: should apply spec correctly
|
||||
|
||||
@@ -28,3 +28,22 @@ tests:
|
||||
asserts:
|
||||
- failedTemplate:
|
||||
errorMessage: Deployment - Expected <rollingUpdate> to be a dictionary, but got [string]
|
||||
|
||||
- it: should fail with both maxSurge and maxUnavailable set to 0
|
||||
set:
|
||||
fallbackDefaults:
|
||||
maxSurge: 0
|
||||
maxUnavailable: 0
|
||||
workload:
|
||||
workload-name:
|
||||
enabled: true
|
||||
primary: true
|
||||
type: Deployment
|
||||
strategy: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 0
|
||||
maxUnavailable: 0
|
||||
podSpec: {}
|
||||
asserts:
|
||||
- failedTemplate:
|
||||
errorMessage: Deployment - Cannot have <maxSurge> and <maxUnavailable> both set to 0
|
||||
|
||||
Reference in New Issue
Block a user