Skip to content

Commit

Permalink
Format output of render command (#1813)
Browse files Browse the repository at this point in the history
  • Loading branch information
phanimarupaka committed May 3, 2021
1 parent d40e7de commit 8cce847
Show file tree
Hide file tree
Showing 10 changed files with 170 additions and 186 deletions.
13 changes: 6 additions & 7 deletions e2e/testdata/fn-render/basicpipeline/.expected/diff.patch
@@ -1,15 +1,14 @@
diff --git a/resources.yaml b/resources.yaml
index 7a494c9..c77c357 100644
index 7a494c9..a9dd224 100644
--- a/resources.yaml
+++ b/resources.yaml
@@ -14,13 +14,26 @@
apiVersion: apps/v1
@@ -15,12 +15,25 @@ apiVersion: apps/v1
kind: Deployment
metadata:
+ labels:
+ tier: backend
name: nginx-deployment
+ namespace: staging
+ labels:
+ tier: backend
spec:
replicas: 3
+ selector:
Expand All @@ -23,9 +22,9 @@ index 7a494c9..c77c357 100644
apiVersion: custom.io/v1
kind: Custom
metadata:
+ labels:
+ tier: backend
name: custom
+ namespace: staging
+ labels:
+ tier: backend
spec:
image: nginx:1.2.3
24 changes: 11 additions & 13 deletions e2e/testdata/fn-render/fnconfig/.expected/diff.patch
@@ -1,16 +1,15 @@
diff --git a/db/resources.yaml b/db/resources.yaml
index ac1fd96..a6c12c6 100644
index ac1fd96..49fa8df 100644
--- a/db/resources.yaml
+++ b/db/resources.yaml
@@ -14,6 +14,19 @@
apiVersion: apps/v1
@@ -15,5 +15,18 @@ apiVersion: apps/v1
kind: StatefulSet
metadata:
name: db
+ namespace: staging
+ labels:
+ app: backend
+ tier: db
name: db
+ namespace: staging
spec:
replicas: 3
+ selector:
Expand All @@ -23,17 +22,16 @@ index ac1fd96..a6c12c6 100644
+ app: backend
+ tier: db
diff --git a/resources.yaml b/resources.yaml
index 7a494c9..5b8e411 100644
index 7a494c9..ac4edf8 100644
--- a/resources.yaml
+++ b/resources.yaml
@@ -14,13 +14,26 @@
apiVersion: apps/v1
@@ -15,12 +15,25 @@ apiVersion: apps/v1
kind: Deployment
metadata:
+ labels:
+ tier: db
name: nginx-deployment
+ namespace: staging
+ labels:
+ tier: db
spec:
replicas: 3
+ selector:
Expand All @@ -47,9 +45,9 @@ index 7a494c9..5b8e411 100644
apiVersion: custom.io/v1
kind: Custom
metadata:
+ labels:
+ tier: db
name: custom
+ namespace: staging
+ labels:
+ tier: db
spec:
image: nginx:1.2.3
image: nginx:1.2.3
34 changes: 16 additions & 18 deletions e2e/testdata/fn-render/generator/.expected/diff.patch
@@ -1,17 +1,17 @@
diff --git a/db/deployment_httpbin.yaml b/db/deployment_httpbin.yaml
new file mode 100644
index 0000000..2bf91c8
index 0000000..0932111
--- /dev/null
+++ b/db/deployment_httpbin.yaml
@@ -0,0 +1,25 @@
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: httpbin
+ namespace: staging
+ labels:
+ app: backend
+ tier: db
+ name: httpbin
+ namespace: staging
+spec:
+ replicas: 4
+ selector:
Expand All @@ -25,23 +25,22 @@ index 0000000..2bf91c8
+ tier: db
+ spec:
+ containers:
+ - image: kennethreitz/httpbin
+ name: httpbin
+ - name: httpbin
+ image: kennethreitz/httpbin
+ ports:
+ - containerPort: 9876
diff --git a/db/resources.yaml b/db/resources.yaml
index ac1fd96..a6c12c6 100644
index ac1fd96..49fa8df 100644
--- a/db/resources.yaml
+++ b/db/resources.yaml
@@ -14,6 +14,19 @@
apiVersion: apps/v1
@@ -15,5 +15,18 @@ apiVersion: apps/v1
kind: StatefulSet
metadata:
name: db
+ namespace: staging
+ labels:
+ app: backend
+ tier: db
name: db
+ namespace: staging
spec:
replicas: 3
+ selector:
Expand All @@ -54,17 +53,16 @@ index ac1fd96..a6c12c6 100644
+ app: backend
+ tier: db
diff --git a/resources.yaml b/resources.yaml
index 7a494c9..5b8e411 100644
index 7a494c9..ac4edf8 100644
--- a/resources.yaml
+++ b/resources.yaml
@@ -14,13 +14,26 @@
apiVersion: apps/v1
@@ -15,12 +15,25 @@ apiVersion: apps/v1
kind: Deployment
metadata:
+ labels:
+ tier: db
name: nginx-deployment
+ namespace: staging
+ labels:
+ tier: db
spec:
replicas: 3
+ selector:
Expand All @@ -78,9 +76,9 @@ index 7a494c9..5b8e411 100644
apiVersion: custom.io/v1
kind: Custom
metadata:
+ labels:
+ tier: db
name: custom
+ namespace: staging
+ labels:
+ tier: db
spec:
image: nginx:1.2.3
image: nginx:1.2.3
13 changes: 6 additions & 7 deletions e2e/testdata/fn-render/inline-fnconfig/.expected/diff.patch
@@ -1,15 +1,14 @@
diff --git a/resources.yaml b/resources.yaml
index 7a494c9..c77c357 100644
index 7a494c9..a9dd224 100644
--- a/resources.yaml
+++ b/resources.yaml
@@ -14,13 +14,26 @@
apiVersion: apps/v1
@@ -15,12 +15,25 @@ apiVersion: apps/v1
kind: Deployment
metadata:
+ labels:
+ tier: backend
name: nginx-deployment
+ namespace: staging
+ labels:
+ tier: backend
spec:
replicas: 3
+ selector:
Expand All @@ -23,9 +22,9 @@ index 7a494c9..c77c357 100644
apiVersion: custom.io/v1
kind: Custom
metadata:
+ labels:
+ tier: backend
name: custom
+ namespace: staging
+ labels:
+ tier: backend
spec:
image: nginx:1.2.3
15 changes: 7 additions & 8 deletions e2e/testdata/fn-render/resource-deletion/.expected/diff.patch
Expand Up @@ -42,17 +42,16 @@ index 0ef5d14..0000000
- - image: kennethreitz/httpbin
- name: httpbin
diff --git a/resources.yaml b/resources.yaml
index 7a494c9..c77c357 100644
index 7a494c9..a9dd224 100644
--- a/resources.yaml
+++ b/resources.yaml
@@ -14,13 +14,26 @@
apiVersion: apps/v1
@@ -15,12 +15,25 @@ apiVersion: apps/v1
kind: Deployment
metadata:
+ labels:
+ tier: backend
name: nginx-deployment
+ namespace: staging
+ labels:
+ tier: backend
spec:
replicas: 3
+ selector:
Expand All @@ -66,9 +65,9 @@ index 7a494c9..c77c357 100644
apiVersion: custom.io/v1
kind: Custom
metadata:
+ labels:
+ tier: backend
name: custom
+ namespace: staging
+ labels:
+ tier: backend
spec:
image: nginx:1.2.3
image: nginx:1.2.3

0 comments on commit 8cce847

Please sign in to comment.