You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 2e704fc
Browse filesBrowse the repository at this point in the historyBrowse files
test(e2e): Gate the Box deploy cases on a Box-capable CDK
Address the review of #2865.
- The Box cases that deploy run only with AGENTCORE_E2E_BOX_CDK, an
@aws/agentcore-cdk version or file: tarball that deploys Box projects;
createTemplateProject installs it in each Box project's agentcore/cdk.
The pinned release still rejects boundRuntime, so the CI-only skip hid
that a laptop run fails at synth the same way. CI sets no opt-in.
- The per-Python Box cases take the same gate, so they also skip without
box on PATH.
- The README says which steps need box: create for a CodeZip box
template, build and deploy (box profile show) for every Box template.
- The egress test throws at collection when its template case is gone,
instead of skipping silently.
- publishInstall renames first and removes the cache folder only when
the rename fails and the folder is not a complete install, and its
comment names the window that remains and EPERM on Windows. A test
covers replacing an interrupted install.
Copy file name to clipboardExpand all lines: e2eTest/README.md
+17-7Lines changed: 17 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,19 +24,29 @@ AGENTCORE_CLI_PATH=/path/to/agentcore bun run test:e2e
24
24
25
25
The `box` tests cover the Strands Box templates, which run their agent in a box. They deploy and
26
26
invoke each one on AgentCore Runtime, and run `agentcore dev` with one local invoke for each. They
27
-
are optional: they run only when a `box` runs from your PATH, and skip otherwise. Create, build and
28
-
deploy of a Box template run `box`, and box ships only arm64 builds, so they skip on the x86_64 Linux
29
-
CI runner. The `dev` tests also need a machine where `box run` can start its sandbox. Box listens on
30
-
the protocol's fixed port (8080, 8000 or 9000), so the `dev` tests run one at a time and need those
31
-
ports free:
27
+
are optional and need a `box` on your PATH: `create` checks for one for a CodeZip box template, and
28
+
`build` and `deploy` run `box profile show` for every Box template, the container one too. Without
29
+
one, they skip. `create` also installs the agent's dependencies and the CDK app's, which `dev` and
30
+
`deploy` use, so the tests don't pass `--skip-install`.
31
+
32
+
The tests that deploy also need `AGENTCORE_E2E_BOX_CDK`: the pinned `@aws/agentcore-cdk` release
33
+
cannot deploy a Box project yet. Set it to an `@aws/agentcore-cdk` version or a `file:` tarball
34
+
that can, for example one packed from the `box-integration` branch of
35
+
[agentcore-l3-cdk-constructs](https://github.com/aws/agentcore-l3-cdk-constructs) with
36
+
`npm run build && npm pack --ignore-scripts`. The tests install it in each Box project's
37
+
`agentcore/cdk`. Without it, as in CI, they skip.
38
+
39
+
The `dev` tests also need a machine where `box run` can start its sandbox, and for the container
40
+
template a container tool. Box listens on the protocol's fixed port (8080, 8000 or 9000), so the
41
+
`dev` tests run one at a time and need those ports free:
32
42
33
43
```sh
34
-
bun run test:e2e -- --tagsFilter='box'
44
+
AGENTCORE_E2E_BOX_CDK=file:/path/to/aws-agentcore-cdk-1.1.0.tgz bun run test:e2e -- --tagsFilter='box'
35
45
```
36
46
37
47
That runs each Box template on its default Python. The CodeZip box template on Python 3.10 to 3.13
38
48
(`py_strands_box_3_10` to `py_strands_box_3_13`) is in the runtime templates describe, so it runs
39
-
with `--tagsFilter='runtime'` or a full run, outside CI.
49
+
with `--tagsFilter='runtime'` or a full run, given `box` and the same opt-in.
40
50
41
51
The `box-egress` test checks that box, under `agentcore dev`, lets the agent reach the host its
42
52
profile allows (`checkip.amazonaws.com`) and blocks any other (`example.com`). It reaches public
0 commit comments