@@ -22,8 +22,8 @@ import { FetchApi } from '@backstage/core-plugin-api';
|
||||
import { GroupedResponses } from '@backstage/plugin-kubernetes-common';
|
||||
import { IContainer } from 'kubernetes-models/v1';
|
||||
import { IContainerStatus } from 'kubernetes-models/v1';
|
||||
import { IIoK8sApimachineryPkgApisMetaV1ObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import type { IIoK8sApimachineryPkgApisMetaV1ObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import type { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import { JsonObject } from '@backstage/types';
|
||||
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
||||
import { KubernetesRequestBody } from '@backstage/plugin-kubernetes-common';
|
||||
@@ -34,11 +34,11 @@ import { Pod } from 'kubernetes-models/v1';
|
||||
import { Pod as Pod_2 } from 'kubernetes-models/v1/Pod';
|
||||
import { ProfileInfoApi } from '@backstage/core-plugin-api';
|
||||
import { ReactNode } from 'react';
|
||||
import { TypeMeta } from '@kubernetes-models/base';
|
||||
import { V1Job } from '@kubernetes/client-node';
|
||||
import { V1ObjectMeta } from '@kubernetes/client-node';
|
||||
import { V1Pod } from '@kubernetes/client-node';
|
||||
import { V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import type { TypeMeta } from '@kubernetes-models/base';
|
||||
import type { V1Job } from '@kubernetes/client-node';
|
||||
import type { V1ObjectMeta } from '@kubernetes/client-node';
|
||||
import type { V1Pod } from '@kubernetes/client-node';
|
||||
import type { V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import { WorkloadsByEntityRequest } from '@backstage/plugin-kubernetes-common';
|
||||
|
||||
// @public (undocumented)
|
||||
|
||||
@@ -20,7 +20,7 @@ import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1CronJob, V1Job } from '@kubernetes/client-node';
|
||||
import type { V1CronJob, V1Job } from '@kubernetes/client-node';
|
||||
import { JobsAccordions } from '../JobsAccordions';
|
||||
import { CronJobDrawer } from './CronJobsDrawer';
|
||||
import { getOwnedResources } from '../../utils/owner';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { V1CronJob } from '@kubernetes/client-node';
|
||||
import type { V1CronJob } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
|
||||
@@ -21,7 +21,7 @@ import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1Pod, V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import type { V1Pod, V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import { PodsTable } from '../../Pods';
|
||||
import { HorizontalPodAutoscalerDrawer } from '../../HorizontalPodAutoscalers';
|
||||
import { RolloutDrawer } from './RolloutDrawer';
|
||||
|
||||
+1
-1
@@ -20,7 +20,7 @@ import AccordionDetails from '@material-ui/core/AccordionDetails';
|
||||
import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1Pod, V1DaemonSet } from '@kubernetes/client-node';
|
||||
import type { V1Pod, V1DaemonSet } from '@kubernetes/client-node';
|
||||
import { PodsTable } from '../Pods';
|
||||
import { DaemonSetDrawer } from './DaemonSetsDrawer';
|
||||
import { getOwnedResources } from '../../utils/owner';
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { V1DaemonSet } from '@kubernetes/client-node';
|
||||
import type { V1DaemonSet } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
import { ReactNode } from 'react';
|
||||
import { V1Deployment } from '@kubernetes/client-node';
|
||||
import type { V1Deployment } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import { renderCondition } from '../../utils/pod';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import {
|
||||
import type {
|
||||
V1Deployment,
|
||||
V1Pod,
|
||||
V2HorizontalPodAutoscaler,
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
import { ReactNode } from 'react';
|
||||
import { V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import type { V2HorizontalPodAutoscaler } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
|
||||
/** @public */
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { V1Ingress } from '@kubernetes/client-node';
|
||||
import type { V1Ingress } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
|
||||
@@ -20,7 +20,7 @@ import AccordionDetails from '@material-ui/core/AccordionDetails';
|
||||
import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1Ingress } from '@kubernetes/client-node';
|
||||
import type { V1Ingress } from '@kubernetes/client-node';
|
||||
import { IngressDrawer } from './IngressDrawer';
|
||||
import { GroupedResponsesContext } from '../../hooks';
|
||||
import { StructuredMetadataTable } from '@backstage/core-components';
|
||||
|
||||
@@ -19,11 +19,14 @@ import { JobsAccordions } from './JobsAccordions';
|
||||
import * as oneCronJobsFixture from '../../__fixtures__/1-cronjobs.json';
|
||||
import { renderInTestApp } from '@backstage/test-utils';
|
||||
import { kubernetesProviders } from '../../hooks/test-utils';
|
||||
import { V1Job } from '@kubernetes/client-node';
|
||||
import { ObjectSerializer } from '@kubernetes/client-node/dist/gen/models/ObjectSerializer';
|
||||
import type { V1Job } from '@kubernetes/client-node';
|
||||
|
||||
describe('JobsAccordions', () => {
|
||||
it('should render 2 jobs', async () => {
|
||||
const { ObjectSerializer } = await import(
|
||||
'@kubernetes/client-node/dist/gen/models/ObjectSerializer'
|
||||
);
|
||||
|
||||
const wrapper = kubernetesProviders(oneCronJobsFixture, new Set<string>());
|
||||
|
||||
const jobs: V1Job[] = oneCronJobsFixture.jobs.map(
|
||||
|
||||
@@ -19,7 +19,7 @@ import AccordionDetails from '@material-ui/core/AccordionDetails';
|
||||
import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1Job, V1Pod } from '@kubernetes/client-node';
|
||||
import type { V1Job, V1Pod } from '@kubernetes/client-node';
|
||||
import { PodsTable } from '../Pods';
|
||||
import { JobDrawer } from './JobsDrawer';
|
||||
import { getOwnedResources } from '../../utils/owner';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { V1Job } from '@kubernetes/client-node';
|
||||
import type { V1Job } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
import { ReactNode, ChangeEvent, useState } from 'react';
|
||||
|
||||
import { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import type { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import Drawer from '@material-ui/core/Drawer';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import IconButton from '@material-ui/core/IconButton';
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@ import Grid from '@material-ui/core/Grid';
|
||||
import { makeStyles, createStyles, Theme } from '@material-ui/core/styles';
|
||||
import Close from '@material-ui/icons/Close';
|
||||
import OpenInNewIcon from '@material-ui/icons/OpenInNew';
|
||||
import { V1ObjectMeta } from '@kubernetes/client-node';
|
||||
import type { V1ObjectMeta } from '@kubernetes/client-node';
|
||||
import { withStyles } from '@material-ui/core/styles';
|
||||
import {
|
||||
LinkButton as BackstageButton,
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ import { Table, TableColumn } from '@backstage/core-components';
|
||||
import { ClusterContext } from '../../hooks/Cluster';
|
||||
import { useMatchingErrors } from '../../hooks/useMatchingErrors';
|
||||
import { Pod } from 'kubernetes-models/v1/Pod';
|
||||
import { V1Pod } from '@kubernetes/client-node';
|
||||
import type { V1Pod } from '@kubernetes/client-node';
|
||||
import { usePodMetrics } from '../../hooks/usePodMetrics';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { V1Service } from '@kubernetes/client-node';
|
||||
import type { V1Service } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
|
||||
@@ -21,7 +21,7 @@ import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import { V1Service } from '@kubernetes/client-node';
|
||||
import type { V1Service } from '@kubernetes/client-node';
|
||||
import { ServiceDrawer } from './ServiceDrawer';
|
||||
import { GroupedResponsesContext } from '../../hooks';
|
||||
import { StructuredMetadataTable } from '@backstage/core-components';
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
import { ReactNode } from 'react';
|
||||
import { V1StatefulSet } from '@kubernetes/client-node';
|
||||
import type { V1StatefulSet } from '@kubernetes/client-node';
|
||||
import { KubernetesStructuredMetadataTableDrawer } from '../KubernetesDrawer';
|
||||
import { renderCondition } from '../../utils/pod';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ import AccordionSummary from '@material-ui/core/AccordionSummary';
|
||||
import Grid from '@material-ui/core/Grid';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
|
||||
import {
|
||||
import type {
|
||||
V1Pod,
|
||||
V2HorizontalPodAutoscaler,
|
||||
V1StatefulSet,
|
||||
|
||||
@@ -18,8 +18,8 @@ import {
|
||||
DetectedError,
|
||||
ResourceRef,
|
||||
} from '@backstage/plugin-kubernetes-common';
|
||||
import { TypeMeta } from '@kubernetes-models/base';
|
||||
import { IIoK8sApimachineryPkgApisMetaV1ObjectMeta as V1ObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import type { TypeMeta } from '@kubernetes-models/base';
|
||||
import type { IIoK8sApimachineryPkgApisMetaV1ObjectMeta as V1ObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
|
||||
/**
|
||||
* Context for detected errors
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { createContext, useContext } from 'react';
|
||||
import { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import type { IObjectMeta } from '@kubernetes-models/apimachinery/apis/meta/v1/ObjectMeta';
|
||||
import { ClientPodStatus } from '@backstage/plugin-kubernetes-common';
|
||||
|
||||
/**
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import {
|
||||
import type {
|
||||
V1ObjectMeta,
|
||||
V2HorizontalPodAutoscaler,
|
||||
V1Pod,
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import {
|
||||
import type {
|
||||
V1Pod,
|
||||
V1PodCondition,
|
||||
V1DeploymentCondition,
|
||||
|
||||
Reference in New Issue
Block a user