Yicong-Huang opened a new pull request, #5203:
URL: https://github.com/apache/texera/pull/5203
### What changes were proposed in this PR?
Adds `HttpClientTestingModule`-based specs for three dashboard services
that previously had no (or near-empty) tests:
- `dataset.service.ts` — pins the URL, HTTP method, body / query string,
and response mapping for every public method, including the
authenticated / anonymous endpoint splits, the presigned-URL chain on
`retrieveDatasetVersionSingleFile`, and the file-node attaching that
`createDatasetVersion` / `retrieveDatasetLatestVersion` perform.
- `workflow-version.service.ts` — replaces a 2-test stub with coverage
of the readonly-display lifecycle (snapshot, swap, restore),
joint-paper highlight helpers, the forward-diff classification in
`getWorkflowsDifference` / `getOperatorsDifference`, and the three
version-API HTTP endpoints.
- `search.service.ts` — covers the authenticated vs public search
routing (with the forced `includePublic=true` on the anonymous path),
the dataset `hasMismatch` filtering inside `executeSearch`, and the
branchy enrich pipeline in `extendSearchResultsWithHubActivityInfo`
(Workflow / Project / Dataset entity routing, activity-list
narrowing, and the workflow-only size-lookup gating).
No production code is touched.
### Any related issues, documentation, discussions?
Closes #5202.
### How was this PR tested?
```
yarn ng test --watch=false \
--include='src/app/dashboard/service/user/dataset/dataset.service.spec.ts'
\
--include='src/app/dashboard/service/user/workflow-version/workflow-version.service.spec.ts'
\
--include='src/app/dashboard/service/user/search.service.spec.ts'
```
Result: 3 specs / 68 tests, all green. Full `yarn ng test --watch=false`
also green (578 passed, 2 skipped, 2 todo). `yarn lint` and
`yarn format:ci` both pass.
### Was this PR authored or co-authored using generative AI tooling?
Generated-by: Claude Opus 4.7
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]