cdk8s-core
cdk8s-core copied to clipboard
Escape hatches seem to not be working as expected
Description of the bug:
The following code:
var test = new KubeNamespace(this, "test", {
metadata: {
name: "test"
}
})
test.addJsonPatch(JsonPatch.add("/spec", { 'test': 1 }))
Generates this:
apiVersion: v1
kind: Namespace
metadata:
name: test
spec: {}
While AFAIK it should generate:
apiVersion: v1
kind: Namespace
metadata:
name: test
spec:
test: 1
Reproduction Steps:
- insert code section into a new Cdk8s TS project
- run
npm run synth
Environment:
- Ubuntu 23
- Node v18.20.0
- Cdk8s 2.198.65
This is :bug: Bug Report