Commit 0fc55fa
committed
fix(integ): assert zero inline SecurityGroupIngress on both SGs in sg-circular verify.sh
The fixture comments (verify.sh, the lib stack JSDoc, and README.md) claim the
script confirms zero inline SecurityGroupIngress entries on either SG, but
verify.sh only ran positive checks (>= 2 standalone AWS::EC2::SecurityGroupIngress
resources, >= 2 carrying SourceSecurityGroupId). It never asserted the inline
Properties.SecurityGroupIngress was empty, so the comment's claim was not
enforced.
Add a jq guard against the synthesized template asserting NO AWS::EC2::SecurityGroup
carries a non-empty Properties.SecurityGroupIngress array (an inline ingress
pointing at the other SG is exactly what would reintroduce the CFn cycle this
fixture exists to avoid). The check fails with a clear message naming the
offending SG logical id(s). BSD/macOS-portable (no grep -P). The existing
comments now match the enforced behavior (review fix).1 parent af2ee04 commit 0fc55fa
1 file changed
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
171 | 188 | | |
172 | 189 | | |
173 | 190 | | |
| |||
0 commit comments