You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by gi...@apache.org on 2026/09/10 15:37:45 UTC
(seatunnel) branch gh-readonly-queue/dev/pr-11818-a55cca1f666a84d5ad12b6537c157e024afb5603 created (now 53333ef488)
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a change to branch gh-readonly-queue/dev/pr-11818-a55cca1f666a84d5ad12b6537c157e024afb5603
in repository https://gitbox.apache.org/repos/asf/seatunnel.git
at 53333ef488 [Fix][Zeta] Add regression test for finished jobs endpoint (#11818)
This branch includes the following new commits:
new 53333ef488 [Fix][Zeta] Add regression test for finished jobs endpoint (#11818)
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(seatunnel) 01/01: [Fix][Zeta] Add regression test for finished jobs endpoint (#11818)
Posted by gi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a commit to branch gh-readonly-queue/dev/pr-11818-a55cca1f666a84d5ad12b6537c157e024afb5603
in repository https://gitbox.apache.org/repos/asf/seatunnel.git
commit 53333ef488fa92e63180bf039ec219b879b4cd72
Author: Jast <sh...@apache.org>
AuthorDate: Thu Sep 10 15:37:25 2026 +0000
[Fix][Zeta] Add regression test for finished jobs endpoint (#11818)
Co-authored-by: zhangshenghang <29...@users.noreply.github.com>
---
.../seatunnel-engine-ui/src/service/job/index.ts | 4 ++--
.../seatunnel-engine-ui/src/tests/jobs.spec.ts | 14 +++++++++++++-
2 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/seatunnel-engine/seatunnel-engine-ui/src/service/job/index.ts b/seatunnel-engine/seatunnel-engine-ui/src/service/job/index.ts
index ad07cc1971..34eda1a267 100644
--- a/seatunnel-engine/seatunnel-engine-ui/src/service/job/index.ts
+++ b/seatunnel-engine/seatunnel-engine-ui/src/service/job/index.ts
@@ -20,7 +20,7 @@ import type { Job, JobPage } from './types'
export const getRunningJobs = (page: number, rows: number) =>
get<JobPage>('/running-jobs/summary', {page: page, rows: rows})
-export const getFinishedJobs = (page: number, rows: number) => get<JobPage>(`/finished-jobs`, {page: page, rows: rows})
+export const getFinishedJobs = (page: number, rows: number) => get<JobPage>('/finished-jobs', {page: page, rows: rows})
export const getJobInfo = (jobId: string) => get<Job>(`/job-info/${jobId}`)
export const getRunningJobInfo = (jobId: string) => get<Job>(`/running-job/${jobId}`)
@@ -29,4 +29,4 @@ export const JobsService = {
getFinishedJobs,
getJobInfo,
getRunningJobInfo
-}
\ No newline at end of file
+}
diff --git a/seatunnel-engine/seatunnel-engine-ui/src/tests/jobs.spec.ts b/seatunnel-engine/seatunnel-engine-ui/src/tests/jobs.spec.ts
index 376667a275..eafd738297 100644
--- a/seatunnel-engine/seatunnel-engine-ui/src/tests/jobs.spec.ts
+++ b/seatunnel-engine/seatunnel-engine-ui/src/tests/jobs.spec.ts
@@ -23,9 +23,12 @@ import { createApp } from 'vue'
import { createPinia, setActivePinia } from 'pinia'
import i18n from '@/locales'
import finishedJobs from '@/views/jobs/finished-jobs'
-import { JobsService } from '@/service/job'
+import { getFinishedJobs, JobsService } from '@/service/job'
+import { get } from '@/service/service'
import type { JobPage, Job } from '@/service/job/types'
+vi.mock('@/service/service', () => ({ get: vi.fn() }))
+
describe('jobs', () => {
const app = createApp({})
beforeEach(() => {
@@ -71,4 +74,13 @@ describe('jobs', () => {
await flushPromises()
expect(wrapper.text()).toContain('SeaTunnel_Job')
})
+
+ test('Finished Jobs service requests all terminal jobs by default', () => {
+ const getMock = vi.mocked(get)
+ getMock.mockClear()
+
+ getFinishedJobs(1, 10)
+
+ expect(getMock).toHaveBeenCalledWith('/finished-jobs', {page: 1, rows: 10})
+ })
})