Skip to content

Commit

Permalink
Update getDetectors URL to match recent API changes
Browse files Browse the repository at this point in the history
This PR addresses a test failure caused by the recent update of the listing detectors URL from '/detectors' to '/detectors/_list' as implemented in server/routes/ad.ts. The change was introduced in opensearch-project/anomaly-detection-dashboards-plugin#739. Previously, the tests in `dashboard_spec.js` and `detector_list_spec.js` were failing because they were waiting for requests to `BASE_AD_NODE_API_PATH + '/detectors*'`, which no longer exists due to the URL update.

Testing:
- Successfully ran all tests in `dashboard_spec.js` and `detector_list_spec.js` to ensure that they now correctly interact with the updated URL.

Signed-off-by: Kaituo Li <[email protected]>
  • Loading branch information
kaituo committed Apr 30, 2024
1 parent a964ed8 commit 6d79a2d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export function getADStopDetectorApiPath(detectorId) {
const BASE_AD_NODE_API_PATH = BASE_PATH + '/api/anomaly_detectors';

export const AD_NODE_API_PATH = {
GET_DETECTORS: BASE_AD_NODE_API_PATH + '/detectors*',
GET_DETECTORS: BASE_AD_NODE_API_PATH + '/detectors/_list*',
GET_INDICES: BASE_AD_NODE_API_PATH + '/_indices*',
GET_MAPPINGS: BASE_AD_NODE_API_PATH + '/_mappings*',
VALIDATE: BASE_AD_NODE_API_PATH + '/detectors/_validate',
Expand Down

0 comments on commit 6d79a2d

Please sign in to comment.