Merge remote-tracking branch 'origin/main' into deploy/dev

This commit is contained in:
yyh
2026-03-17 11:01:43 +08:00
212 changed files with 385022 additions and 5292 deletions

View File

@ -1,4 +1,4 @@
import type { DataSourceAuth } from './types'
import type { DataSourceAuth } from '../types'
import { fireEvent, render, screen, waitFor, within } from '@testing-library/react'
import { FormTypeEnum } from '@/app/components/base/form/types'
import { usePluginAuthAction } from '@/app/components/plugins/plugin-auth'
@ -8,8 +8,8 @@ import { useRenderI18nObject } from '@/hooks/use-i18n'
import { openOAuthPopup } from '@/hooks/use-oauth'
import { useGetDataSourceOAuthUrl, useInvalidDataSourceAuth, useInvalidDataSourceListAuth, useInvalidDefaultDataSourceListAuth } from '@/service/use-datasource'
import { useInvalidDataSourceList } from '@/service/use-pipeline'
import Card from './card'
import { useDataSourceAuthUpdate } from './hooks'
import Card from '../card'
import { useDataSourceAuthUpdate } from '../hooks'
vi.mock('@/app/components/plugins/plugin-auth', () => ({
ApiKeyModal: vi.fn(({ onClose, onUpdate, onRemove, disabled, editValues }: { onClose: () => void, onUpdate: () => void, onRemove: () => void, disabled: boolean, editValues: Record<string, unknown> }) => (
@ -43,7 +43,7 @@ vi.mock('@/service/use-datasource', () => ({
useInvalidDefaultDataSourceListAuth: vi.fn(() => vi.fn()),
}))
vi.mock('./hooks', () => ({
vi.mock('../hooks', () => ({
useDataSourceAuthUpdate: vi.fn(),
}))

View File

@ -1,10 +1,10 @@
import type { DataSourceAuth } from './types'
import type { DataSourceAuth } from '../types'
import type { FormSchema } from '@/app/components/base/form/types'
import type { AddApiKeyButtonProps, AddOAuthButtonProps, PluginPayload } from '@/app/components/plugins/plugin-auth/types'
import { fireEvent, render, screen, waitFor } from '@testing-library/react'
import { FormTypeEnum } from '@/app/components/base/form/types'
import { AuthCategory } from '@/app/components/plugins/plugin-auth/types'
import Configure from './configure'
import Configure from '../configure'
/**
* Configure Component Tests

View File

@ -1,5 +1,5 @@
import type { UseQueryResult } from '@tanstack/react-query'
import type { DataSourceAuth } from './types'
import type { DataSourceAuth } from '../types'
import { render, screen } from '@testing-library/react'
import { useTheme } from 'next-themes'
import { usePluginAuthAction } from '@/app/components/plugins/plugin-auth'
@ -7,8 +7,8 @@ import { useGlobalPublicStore } from '@/context/global-public-context'
import { useRenderI18nObject } from '@/hooks/use-i18n'
import { useGetDataSourceListAuth, useGetDataSourceOAuthUrl } from '@/service/use-datasource'
import { defaultSystemFeatures } from '@/types/feature'
import { useDataSourceAuthUpdate, useMarketplaceAllPlugins } from './hooks'
import DataSourcePage from './index'
import { useDataSourceAuthUpdate, useMarketplaceAllPlugins } from '../hooks'
import DataSourcePage from '../index'
/**
* DataSourcePage Component Tests
@ -33,7 +33,7 @@ vi.mock('@/service/use-datasource', () => ({
useGetDataSourceOAuthUrl: vi.fn(),
}))
vi.mock('./hooks', () => ({
vi.mock('../hooks', () => ({
useDataSourceAuthUpdate: vi.fn(),
useMarketplaceAllPlugins: vi.fn(),
}))

View File

@ -1,10 +1,10 @@
import type { DataSourceAuth } from './types'
import type { DataSourceAuth } from '../types'
import type { Plugin } from '@/app/components/plugins/types'
import { fireEvent, render, screen } from '@testing-library/react'
import { useTheme } from 'next-themes'
import { PluginCategoryEnum } from '@/app/components/plugins/types'
import { useMarketplaceAllPlugins } from './hooks'
import InstallFromMarketplace from './install-from-marketplace'
import { useMarketplaceAllPlugins } from '../hooks'
import InstallFromMarketplace from '../install-from-marketplace'
/**
* InstallFromMarketplace Component Tests
@ -54,7 +54,7 @@ vi.mock('@/app/components/plugins/provider-card', () => ({
),
}))
vi.mock('./hooks', () => ({
vi.mock('../hooks', () => ({
useMarketplaceAllPlugins: vi.fn(),
}))

View File

@ -1,7 +1,7 @@
import type { DataSourceCredential } from './types'
import type { DataSourceCredential } from '../types'
import { fireEvent, render, screen } from '@testing-library/react'
import { CredentialTypeEnum } from '@/app/components/plugins/plugin-auth/types'
import Item from './item'
import Item from '../item'
/**
* Item Component Tests

View File

@ -1,7 +1,7 @@
import type { DataSourceCredential } from './types'
import type { DataSourceCredential } from '../types'
import { fireEvent, render, screen } from '@testing-library/react'
import { CredentialTypeEnum } from '@/app/components/plugins/plugin-auth/types'
import Operator from './operator'
import Operator from '../operator'
/**
* Operator Component Tests

View File

@ -5,7 +5,7 @@ import {
useInvalidDefaultDataSourceListAuth,
} from '@/service/use-datasource'
import { useInvalidDataSourceList } from '@/service/use-pipeline'
import { useDataSourceAuthUpdate } from './use-data-source-auth-update'
import { useDataSourceAuthUpdate } from '../use-data-source-auth-update'
/**
* useDataSourceAuthUpdate Hook Tests

View File

@ -5,7 +5,7 @@ import {
useMarketplacePluginsByCollectionId,
} from '@/app/components/plugins/marketplace/hooks'
import { PluginCategoryEnum } from '@/app/components/plugins/types'
import { useMarketplaceAllPlugins } from './use-marketplace-all-plugins'
import { useMarketplaceAllPlugins } from '../use-marketplace-all-plugins'
/**
* useMarketplaceAllPlugins Hook Tests