Skip to content

Migrate VansahNode to Vansah API v2 (folderPath, Space Key, Test Plans)#2

Open
ShubhamMour wants to merge 6 commits into
prodfrom
fix/vansahnode-removetestlog-debug-spacekey-test-plan
Open

Migrate VansahNode to Vansah API v2 (folderPath, Space Key, Test Plans)#2
ShubhamMour wants to merge 6 commits into
prodfrom
fix/vansahnode-removetestlog-debug-spacekey-test-plan

Conversation

@ShubhamMour

@ShubhamMour ShubhamMour commented Jul 17, 2026

Copy link
Copy Markdown

Changes

  • API v2 migration — all run/log endpoints now use /api/v2/*. Connect tokens work end-to-end.
  • Folder asset fix — folder runs use folderPath (not the old identifier).
  • Space Key scoping — top-level project.key is now sent on every request (required for Connect tokens; fixes errorCode 1306).
  • Test Plan support — Standard and Advanced Test Plan runs via Java-style setters (setStandardTestPlanKey, setAdvancedTestPlanKey, setTestPlanIteration) + AddTestRunFromStandardTestPlan / AddTestRunFromAdvancedTestPlan. Iteration defaults to 1
  • Cleanup — removed the dead testScripts endpoint declaration .
  • README — Updated (features, configuration, usage, method overview). Added license.md.
  • Test harnesstest/ contains a .env-driven end-to-end harness (VansahNodeFullTests.cs) that exercises every function; .env.example documents the required keys. Real .env and build output stay gitignored.

- Use API v2 (v1 rejects Vansah Connect tokens).
- Folder asset uses folderPath (not identifier) -- fixes errorCode 1306.
- Send top-level project.key (Space Key) scoping on every run.
- Add Standard/Advanced Test Plan run methods.
- Create runs UNTESTED and resolve each step's pre-created log from a cached
  map (step number -> log id); AddTestLog updates it (or creates a fallback),
  and RemoveTestLog recreates an UNTESTED placeholder so the cache stays valid.
- Add setDebug payload logging (token never printed).
- Ship as a class library and drop the old executable sample.

Ignore local secrets and the local test harness (.env, .env.example, localtests/).
- Test Plan API now uses setters, matching the Java binding:
  setStandardTestPlanKey(key), setAdvancedTestPlanKey(key), setTestPlanIteration(int).
  Run methods become AddTestRunFromStandardTestPlan(testCase) and
  AddTestRunFromAdvancedTestPlan(testPlanAssetType, testCase).
- Iteration defaults to 1, valid range 1-5 (out-of-range warns and keeps 1),
  and applies only to Test Plan runs. The API requires iteration on planned
  runs, so it is always sent (defaulting to 1).
- Rewrite README to mirror the Java binding's structure (Features, Prerequisite,
  Configuration, Dependencies, Usage examples, Methods Overview, Setter Methods)
  with C#-accurate signatures and the new setter-based Test Plan usage.
- Keep any local test harness out of the library build.
- Test Plan API now uses setters, matching the Java binding:
  setStandardTestPlanKey(key), setAdvancedTestPlanKey(key), setTestPlanIteration(int).
  Run methods become AddTestRunFromStandardTestPlan(testCase) and
  AddTestRunFromAdvancedTestPlan(testPlanAssetType, testCase).
- Iteration defaults to 1, valid range 1-5 (out-of-range warns and keeps 1),
  and applies only to Test Plan runs. The API requires iteration on planned
  runs, so it is always sent (defaulting to 1).
- Rewrite README to mirror the Java binding's structure (Features, Prerequisite,
  Configuration, Dependencies, Usage examples, Methods Overview, Setter Methods)
  with C#-accurate signatures and the new setter-based Test Plan usage.
- Keep any local test harness out of the library build.
@ShubhamMour
ShubhamMour requested a review from fadihawli July 17, 2026 12:49
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