mirror of
https://github.com/yannh/kubeconform.git
synced 2026-02-11 14:09:21 +00:00
Add test validating using CRD that misses explicit draft version
This commit is contained in:
parent
51065ea828
commit
a2ad239853
2 changed files with 18 additions and 0 deletions
|
|
@ -340,3 +340,8 @@ resetCacheFolder() {
|
|||
run xmllint --noout --schema fixtures/junit.xsd output.xml
|
||||
[ "$status" -eq 0 ]
|
||||
}
|
||||
|
||||
@test "passes when trying to use a CRD that does not have the JSONSchema set" {
|
||||
run bash -c "bin/kubeconform -schema-location default -schema-location 'https://raw.githubusercontent.com/datreeio/CRDs-catalog/main/{{.Group}}/{{.ResourceKind}}_{{.ResourceAPIVersion}}.json' fixtures/httpproxy.yaml"
|
||||
[ "$status" -eq 0 ]
|
||||
}
|
||||
|
|
|
|||
13
fixtures/httpproxy.yaml
Normal file
13
fixtures/httpproxy.yaml
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
apiVersion: projectcontour.io/v1
|
||||
kind: HTTPProxy
|
||||
metadata:
|
||||
name: basic
|
||||
spec:
|
||||
virtualhost:
|
||||
fqdn: foo-basic.example.com
|
||||
routes:
|
||||
- conditions:
|
||||
- prefix: /
|
||||
services:
|
||||
- name: s1
|
||||
port: 80
|
||||
Loading…
Reference in a new issue