test(uipath-agents): coded anti-pattern + bindings sweep tests (PR 5/5)#476
Conversation
|
Claude finished @radugheo's task in 2m 39s —— View job SummaryAdds seven coder_eval test tasks (four anti-pattern smoke tests, three bindings-sweep e2e tests) and six Python check scripts for the Change-by-Change Review1. Anti-pattern task YAMLs (4 files)Severity: OK — Tags are correct ( 2. Bindings sweep task YAMLs (3 files)Severity: Medium — Tags are correct (
All 16 existing tasks in 3.
|
| Area | Status | Notes |
|---|---|---|
| Frontmatter | N/A | No skill changes — tests only |
| E2E Tests | Issue | task_id naming inconsistency on bindings tasks |
| Skill Body | N/A | No skill changes |
| References & Assets | N/A | No skill changes |
| Repo Hygiene | OK | No secrets, no personal paths, no cross-skill refs, changes scoped to test tasks |
Issues for Manual Review
- The
indexbinding (check_bindings_queue_app_index.py:49) assertsActivityName="retrieve_async"even though the call site issearch_async. The check comment explains this matches the bindings reference ("ALL methods bind viaretrieve_async"). Verify this is still the current contract — if the reference changes, this assertion will silently pass incorrect bindings. - The
antipattern_login_no_tenanttask seeds only a goal prompt (no project files). Verify the skill activates correctly from a bare auth request without a pre-existing project context.
Conclusion
Clean PR. The tests are well-designed with good positive/negative coverage and correct use of shared helpers. One Medium issue: the three bindings task_id values should align with the established skill-agent-coded-* convention. One Low cosmetic: the WRONG regex in check_antipattern_wrong_sdk_import.py could use \b instead of (?:\s*,|$) for consistency with the RIGHT regex on the same page. Neither blocks merge.
15da95f to
4aa145b
Compare
0e6d5a8 to
14f863f
Compare
4aa145b to
23b712b
Compare
14f863f to
684055a
Compare
23b712b to
2a98b40
Compare
684055a to
7c742c4
Compare
2a98b40 to
d949d53
Compare
7c742c4 to
a290b64
Compare
d949d53 to
9ed1291
Compare
a290b64 to
aa14992
Compare
9ed1291 to
fa8bc6b
Compare
aa14992 to
7e708c0
Compare
fa8bc6b to
a2b7c01
Compare
7e708c0 to
bf81f67
Compare
a2b7c01 to
d168789
Compare
bf81f67 to
97e8686
Compare
d168789 to
59ee4c3
Compare
6221f86 to
b9f704e
Compare
72a8cc6 to
23543b3
Compare
b9f704e to
310ccec
Compare
23543b3 to
e3cfe5b
Compare
310ccec to
36ddc2e
Compare
e3cfe5b to
f48ca21
Compare
36ddc2e to
c3506a6
Compare
f48ca21 to
88fa6a4
Compare
c3506a6 to
cfc79d0
Compare
88fa6a4 to
b759597
Compare
cfc79d0 to
2f9ec34
Compare
b759597 to
c77a1bc
Compare
2f9ec34 to
71a8126
Compare
c77a1bc to
6924bbd
Compare
Anti-pattern smokes — each task seeds a violating project layout and the skill must drive the agent to detect and fix the violation: - skill-agent-coded-antipattern-build-system — pre-seeded pyproject.toml carries [build-system] hatchling. Check verifies the section is removed and [project] survives. - skill-agent-coded-antipattern-module-level-llm — pre-seeded LangGraph main.py constructs UiPathChat() at module level. Check verifies no module-level UiPath* construction remains and the top-level `graph` variable is preserved. - skill-agent-coded-antipattern-wrong-sdk-import — pre-seeded main.py uses `from uipath import UiPath` (raises ImportError). Check verifies the import was switched to `from uipath.platform import UiPath`. Bindings sweep tests (e2e): - skill-agents-bindings-queue-app-index — five binding types in one project (queue, app, index, connection, mcpServer). Asserts one entry per resource with correct keys, value blocks, and metadata. Connection key is bare; queue with no folder_path is also bare (per the bindings reference No-folder edge case). - skill-agents-bindings-asset-subtypes — three asset retrieves annotated str / int / bool. Asserts three asset bindings; per-binding SubType either matches the annotation (stringAsset / integerAsset / booleanAsset) OR is omitted (the bindings reference allows the omit-fallback). Wrong SubType fails — that would mis-place the resource at uipath push time. - skill-agents-bindings-multi-entrypoint — entry-points.json with two entrypoints. Asserts each binding's EntryPointUniqueId references one of the real entrypoints (or no link at all); fabricated UUIDs fail.
71a8126 to
d4a4df7
Compare
Summary
Adds seven coded-agent tests — four anti-pattern smokes that verify the skill catches the most expensive coded mistakes, plus three bindings-sweep tests that close the binding-resource and entrypoint-resolution gaps.
Anti-pattern tests (smoke)
Each task seeds a violating project layout in the prompt; the skill must drive the agent to detect and fix the violation in place.
skill-agent-coded-antipattern-build-systempyproject.tomlwith[build-system](hatchling). Check verifies the section is removed and[project]survives.skill-agent-coded-antipattern-module-level-llmmain.pywithllm = UiPathChat(...)at module level. Check verifies no module-level UiPath* construction remains and the top-levelgraphvariable is preserved.skill-agent-coded-antipattern-wrong-sdk-importfrom uipath import UiPath(raisesImportError). Check verifies the import was switched tofrom uipath.platform import UiPath.skill-agent-coded-antipattern-login-no-tenantuip login --output jsonanduip login tenant set "MyTenant"were both run.Bindings sweep tests (e2e)
skill-agents-bindings-queue-app-indexqueue,app,index,connection,mcpServer. Asserts one entry per resource with the correct key (bare for connections; bare for the no-folder queue), value block, and metadata (ActivityName,DisplayLabel,UseConnectionService).skill-agents-bindings-asset-subtypesstr/int/bool. Asserts three asset bindings; per-bindingmetadata.SubTypeeither matches the annotation (stringAsset/integerAsset/booleanAsset) OR is omitted. A wrong SubType fails — that would mis-place the resource atuipath pushtime.skill-agents-bindings-multi-entrypointentry-points.jsonwith two entrypoints, two SDK calls across two source files. Asserts each binding'sEntryPointUniqueIdreferences one of the real entrypoints (or has no entrypoint link at all); fabricated UUIDs fail.Stacked on #475.
Test plan
check_*.pyscripts dry-run green against synthetic well-formed projects (the seventh task,antipattern-login-no-tenant, has no sidecar — purecommand_executedchecks).[build-system]in fails the build-system check;from uipath import UiPathfails the import check; a fabricated entrypoint UUID fails the multi-entrypoint check;SubType="credentialAsset"on astr-annotated retrieve fails the asset-subtypes check.coded/parse and tag lists are consistent.