jbangdev / jbang-action

Docker image and Github Action to run jbang scripts
https://jbang.dev
MIT License
40 stars 11 forks source link

fix(container-structure-test): adapt expectedError regex #37

Closed beiertu-mms closed 4 months ago

beiertu-mms commented 7 months ago

The brackets [] seems to cause the regex to be parsed wrongly when using container-structure-test. Therefore, split it into multiple regex and check for each strings individually.

Follow up of https://github.com/jbangdev/jbang-action/pull/36

Related to https://github.com/jbangdev/jbang-action/issues/35

beiertu-mms commented 7 months ago

@maxandersen I'm sorry, but this should now fix the error. I verify it with a simple workflow in my fork (https://github.com/beiertu-mms/jbang-action/pull/2).

maxandersen commented 7 months ago

Isn't it enough to have it be [ and ]?

beiertu-mms commented 7 months ago

Isn't it enough to have it be [ and ]?

you mean like this?

regex: ["Trusting permanently:", "https://github.com/jruby"]

Edit: or you mean to have it like this?


regex:
  - "[Trusting permanently:]"
  - "[https://github.com/jruby]"
maxandersen commented 4 months ago

this was missed because the container test file actually comes from github.com/jbangdev/jbang repo. 0.117.1 should have fix for this.