integ-runner: new integration tests always throw "Please use the IntegTest construct to configure the test" #28549
Labels
@aws-cdk/integ-runner
bug
This issue is a bug.
effort/medium
Medium work item – several days of effort
p2
Describe the bug
Every once in a while, it seems like a change to the manifests generated by the
integ-runner
code causes us to have to wipe out the.snapshot
directory and start over. We'll do an update to the CDK libraries, and see an error like this:The thing is, when we wipe out the
.snapshot
directory to just start over:We will get a fun new error:
After digging through the code, I see two lines that don't make sense to me...
At
aws-cdk/packages/@aws-cdk/integ-runner/lib/runner/integ-test-runner.ts
Line 78 in 166967f
(!this.hasSnapshot() && this.isLegacyTest) ... then throw error
. Fine... we deleted the snapshot so that part makes sense, but then what is thisisLegacyTest
bit? Well according toaws-cdk/packages/@aws-cdk/integ-runner/lib/runner/runner-base.ts
Lines 209 to 237 in 166967f
isLegacyTest=true
if there is nointeg.json
file .. but of course there isn't, because there's no.snapshot
at all!What am I missing here? It seems like this is designed to break if you try to generate a fresh snapshot?
Expected Behavior
I'd expect it to just create a new snapshot from scratch based on the current code base.
Current Behavior
See above.
Reproduction Steps
See above.
Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.116.1
Framework Version
No response
Node.js Version
18
OS
OSX
Language
TypeScript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: