Skip to content

test(e2e): make E2E suite robust to non-US / keypair / branched-storage projects - #391

Merged
padak merged 1 commit into
mainfrom
fix/e2e-test-env-robustness
Jun 4, 2026
Merged

test(e2e): make E2E suite robust to non-US / keypair / branched-storage projects#391
padak merged 1 commit into
mainfrom
fix/e2e-test-env-robustness

Conversation

@padak

@padak padak commented Jun 4, 2026

Copy link
Copy Markdown
Member

Why

The nightly e2e.yml from #385 ran the E2E suite against a GCP / Snowflake-keypair project for the first time — a different environment than the US / password stack the suite was originally written against. After fixing a doubled E2E_URL secret (operator config, which had caused an unrelated metastore-URL cascade), 6 real failures remained. All are test / environment robustness, not product bugs — no product code is touched here.

This PR fixes the 4 test-side ones. The other 2 (NativeTypes/BranchMaterialize, CloneTable) were purely environmental (branched storage was disabled on the project) and pass once it is enabled.

What (tests only)

  • ConfigSecretEncryption ×2 — read created["data"]["id"], not created["id"]. config new --push returns the standard {status, data} envelope; the test forgot to unwrap ["data"] (the sibling _test_config_new_push already does it). Manifested as KeyError: 'id'.
  • swap-tables rejection test — assert "requires a branch" instead of the old "dev branch" wording. The message was corrected in fix(storage): correct stale "dev branch only" swap-tables wording #373 (swap works on any branch, incl. production); the CLI test was updated there but this E2E assertion was missed.
  • FullE2E workspace password — keypair-auth workspaces (Snowflake person-keypair login) have no password, so the API returns HTTP 400 "not supported for login type …". Skip that one step cleanly instead of failing the whole run.
  • metastore_scope_available preflight — also treat an unreachable metastore host (connection error) as "scope unavailable" and skip, so a misconfigured stack URL yields one clean skip instead of a wall of errors across every dependent test.

Verification

Out of scope

  • No product code changed (tests + one E2E preflight helper only).
  • NativeTypes / CloneTable were branched-storage-off (environment), not code.

Open in Devin Review

…ge projects

Surfaced by running the E2E suite in CI against a GCP / Snowflake-keypair
project (the new nightly e2e.yml from #385). All findings are test/environment
robustness, NOT product bugs -- no product code changed.

- ConfigSecretEncryption (x2): read `created["data"]["id"]`, not
  `created["id"]`. `config new --push` returns the standard `{status, data}`
  envelope; the test forgot to unwrap `["data"]` (the sibling
  `_test_config_new_push` already does). Manifested as `KeyError: 'id'`.
- swap-tables rejection test: assert `"requires a branch"` instead of the old
  `"dev branch"` wording. The wording was corrected in #373 (swap works on any
  branch, incl. production); the CLI test was updated there but this E2E
  assertion was missed.
- FullE2E workspace password: keypair-auth workspaces (Snowflake
  person-keypair login) have no password, so the API returns HTTP 400
  "not supported for login type ..." -- skip that step cleanly instead of
  failing the whole run.
- metastore_scope_available preflight: also treat an unreachable metastore
  host (connection error) as "scope unavailable" and skip, so a misconfigured
  stack URL yields one clean skip instead of a wall of errors across every
  dependent test.
@padak
padak merged commit 039faa2 into main Jun 4, 2026
8 of 9 checks passed
@padak
padak deleted the fix/e2e-test-env-robustness branch June 4, 2026 20:20

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

View 3 additional findings in Devin Review.

Open in Devin Review

Comment thread tests/test_e2e.py
Comment on lines +7407 to +7408
# match the stable part of the message, not the old "dev branch" phrasing.
assert "requires a branch" in payload["error"]["message"]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚩 Assertion wording change assumes PR #373 is merged

Line 7408 changes the assertion from "dev branch" in payload["error"]["message"] to "requires a branch" in payload["error"]["message"]. The comment explains the wording was corrected in PR #373 (swap works on any branch, including production). If this PR is merged before #373, or if #373's wording doesn't contain exactly "requires a branch", this E2E test would fail. Since the PR is presumably based on a branch that includes #373's changes, this is fine — but worth verifying during review that the merge-base includes the wording change.

Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant