ccqa 1.40.6 → 1.40.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bin/ccqa.mjs CHANGED
@@ -15289,12 +15289,18 @@ function assertToLine(action, locator) {
15289
15289
  return assertLine ?? comment;
15290
15290
  }
15291
15291
  /**
15292
- * `url_contains` → toHaveURL. Literal values become an unanchored RegExp
15293
- * (substring match); values carrying env refs can't live in a regex literal,
15294
- * so they use toHaveURL's glob form with a template literal.
15292
+ * `url_contains` → "the URL contains this".
15293
+ *
15294
+ * A `${VAR}` only has a value at run time, which rules out both forms that take
15295
+ * the pattern up front: a regular expression would have to match the reference
15296
+ * span with `.*` (so `${APP_BASE_URL}` alone would assert nothing at all), and
15297
+ * the glob `toHaveURL` accepts is compared against the whole URL, so an
15298
+ * absolute one never matches. Polling `page.url()` keeps the substring
15299
+ * semantic and the resolved value.
15295
15300
  */
15296
15301
  function urlContainsAssert(value) {
15297
- if (jExpr(value).startsWith("`")) return `await expect(page).toHaveURL(${envRefsToJsExpression(`**${value}**`)});`;
15302
+ const expr = jExpr(value);
15303
+ if (expr.startsWith("`")) return `await expect.poll(() => page.url()).toContain(${expr});`;
15298
15304
  return `await expect(page).toHaveURL(new RegExp(${j(escapeRegExp(value))}));`;
15299
15305
  }
15300
15306
  function escapeRegExp(s) {
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccqa",
3
- "version": "1.40.6",
3
+ "version": "1.40.7",
4
4
  "type": "module",
5
5
  "description": "Browser test recorder powered by Claude Code and agent-browser",
6
6
  "repository": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccqa",
3
- "version": "1.40.6",
3
+ "version": "1.40.7",
4
4
  "type": "module",
5
5
  "description": "Browser test recorder powered by Claude Code and agent-browser",
6
6
  "repository": {