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
thrownewEnvVarsException("Unable to find " + messageContext + " which is required.");
178
+
thrownewEnvVarsException("Missing selector \"" + selector + "\". Unable to find an element named \"" + selector + "\" inside the node \"" + node.context + "\", and rules for this node require that it exists.");
181
179
} else {
182
180
// Selector not found. Selector not required. Do nothing, and be happy about it.
183
181
returnnull;
184
182
}
185
183
}
186
184
187
185
if (!(currentScopeObjectinstanceofMap)) {
188
-
thrownewEnvVarsException("The element " + messageContext + " must be a map, but it is not.");
186
+
thrownewEnvVarsException("Invalid selector \"" + selector + "\". The element \"" + selector + "\" inside the node \"" + node.context + "\" must be a map, but it is not.");
thrownewEnvVarsException("The element " + messageContext + " must be a map, but it is not.");
267
+
thrownewEnvVarsException("Invalid context \"" + mapName + "\". The element \"" + mapName + "\" inside the selector \"" + selector + "\" inside the node \"" + node.context + "\" must be a map, but it is not.");
Copy file name to clipboardExpand all lines: envvars-lib/src/test/groovy/com/optum/envvars/EnvVarEngineSpec.groovy
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -75,7 +75,7 @@ class EnvVarEngineSpec extends Specification {
75
75
76
76
then:
77
77
EnvVarsException ex = thrown()
78
-
ex.message =='Unable to find [environments:missing] which is required.'
78
+
ex.message =='Missing selector "missing". Unable to find an element named "missing" inside the node "environments", and rules for this node require that it exists.'
Copy file name to clipboardExpand all lines: envvars-lib/src/test/groovy/com/optum/envvars/EnvVarMapDataEngineSpec.groovy
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -65,7 +65,7 @@ class EnvVarMapDataEngineSpec extends Specification {
65
65
66
66
then:
67
67
EnvVarsException ex = thrown()
68
-
ex.message =='Unable to find [environments:missing] which is required.'
68
+
ex.message =='Missing selector "missing". Unable to find an element named "missing" inside the node "environments", and rules for this node require that it exists.'
69
69
}
70
70
71
71
def"SELECTOR: Missing optional selector" () {
@@ -108,7 +108,7 @@ class EnvVarMapDataEngineSpec extends Specification {
108
108
109
109
then:
110
110
EnvVarsException ex = thrown()
111
-
ex.message =='The element [environments:env1:define] must be a map, but it is not.'
111
+
ex.message =='Invalid context "define". The element "define" inside the selector "env1" inside the node "environments" must be a map, but it is not.'
112
112
}
113
113
114
114
def"BLOCK: Bad secretEnvvars" () {
@@ -119,7 +119,7 @@ class EnvVarMapDataEngineSpec extends Specification {
119
119
120
120
then:
121
121
EnvVarsException ex = thrown()
122
-
ex.message =='The element [environments:env2:defineSecrets] must be a map, but it is not.'
122
+
ex.message =='Invalid context "defineSecrets". The element "defineSecrets" inside the selector "env2" inside the node "environments" must be a map, but it is not.'
123
123
}
124
124
125
125
def"BLOCK: Bad injectEnvvars" () {
@@ -152,7 +152,7 @@ class EnvVarMapDataEngineSpec extends Specification {
152
152
153
153
then:
154
154
EnvVarsException ex = thrown()
155
-
ex.message =='The element [environments:badenv] must be a map, but it is not.'
155
+
ex.message =='Invalid selector "badenv". The element "badenv" inside the node "environments" must be a map, but it is not.'
156
156
}
157
157
/**
158
158
* Three different flows, so each test in each of these blocks: envvars, injectedEnvvars, injectedQualifiedEnvvars.
@@ -465,7 +465,7 @@ class EnvVarMapDataEngineSpec extends Specification {
465
465
466
466
then:
467
467
EnvVarsException ex = thrown()
468
-
ex.message =='Unable to find [applications:default] which is required.'
468
+
ex.message =='Missing selector "default". Unable to find an element named "default" inside the node "applications", and rules for this node require that it exists.'
0 commit comments