Merge pull request #6170 from RoadieHQ/relationship-card-titles
Improved titles for relationship cards
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-catalog': patch
|
||||
---
|
||||
|
||||
Clearer titles for the relationship cards
|
||||
+2
-2
@@ -66,7 +66,7 @@ describe('<DependsOnResourcesCard />', () => {
|
||||
</Wrapper>,
|
||||
);
|
||||
|
||||
expect(getByText('Resources')).toBeInTheDocument();
|
||||
expect(getByText('Depends on resources')).toBeInTheDocument();
|
||||
expect(
|
||||
getByText(/No resource is a dependency of this component/i),
|
||||
).toBeInTheDocument();
|
||||
@@ -114,7 +114,7 @@ describe('<DependsOnResourcesCard />', () => {
|
||||
);
|
||||
|
||||
await waitFor(() => {
|
||||
expect(getByText('Resources')).toBeInTheDocument();
|
||||
expect(getByText('Depends on resources')).toBeInTheDocument();
|
||||
expect(getByText(/target-name/i)).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -31,7 +31,7 @@ export const DependsOnResourcesCard = ({ variant = 'gridItem' }: Props) => {
|
||||
return (
|
||||
<RelatedEntitiesCard
|
||||
variant={variant}
|
||||
title="Resources"
|
||||
title="Depends on resources"
|
||||
entityKind="Resource"
|
||||
relationType={RELATION_DEPENDS_ON}
|
||||
columns={resourceEntityColumns}
|
||||
|
||||
@@ -66,7 +66,7 @@ describe('<HasComponentsCard />', () => {
|
||||
</Wrapper>,
|
||||
);
|
||||
|
||||
expect(getByText('Components')).toBeInTheDocument();
|
||||
expect(getByText('Has components')).toBeInTheDocument();
|
||||
expect(
|
||||
getByText(/No component is part of this system/i),
|
||||
).toBeInTheDocument();
|
||||
@@ -114,7 +114,7 @@ describe('<HasComponentsCard />', () => {
|
||||
);
|
||||
|
||||
await waitFor(() => {
|
||||
expect(getByText('Components')).toBeInTheDocument();
|
||||
expect(getByText('Has components')).toBeInTheDocument();
|
||||
expect(getByText(/target-name/i)).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -31,7 +31,7 @@ export const HasComponentsCard = ({ variant = 'gridItem' }: Props) => {
|
||||
return (
|
||||
<RelatedEntitiesCard
|
||||
variant={variant}
|
||||
title="Components"
|
||||
title="Has components"
|
||||
entityKind="Component"
|
||||
relationType={RELATION_HAS_PART}
|
||||
columns={componentEntityColumns}
|
||||
|
||||
@@ -66,7 +66,7 @@ describe('<HasResourcesCard />', () => {
|
||||
</Wrapper>,
|
||||
);
|
||||
|
||||
expect(getByText('Resources')).toBeInTheDocument();
|
||||
expect(getByText('Has resources')).toBeInTheDocument();
|
||||
expect(
|
||||
getByText(/No resource is part of this system/i),
|
||||
).toBeInTheDocument();
|
||||
@@ -114,7 +114,7 @@ describe('<HasResourcesCard />', () => {
|
||||
);
|
||||
|
||||
await waitFor(() => {
|
||||
expect(getByText('Resources')).toBeInTheDocument();
|
||||
expect(getByText('Has resources')).toBeInTheDocument();
|
||||
expect(getByText(/target-name/i)).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -31,7 +31,7 @@ export const HasResourcesCard = ({ variant = 'gridItem' }: Props) => {
|
||||
return (
|
||||
<RelatedEntitiesCard
|
||||
variant={variant}
|
||||
title="Resources"
|
||||
title="Has resources"
|
||||
entityKind="Resource"
|
||||
relationType={RELATION_HAS_PART}
|
||||
columns={resourceEntityColumns}
|
||||
|
||||
@@ -66,7 +66,7 @@ describe('<HasSubcomponentsCard />', () => {
|
||||
</Wrapper>,
|
||||
);
|
||||
|
||||
expect(getByText('Subcomponents')).toBeInTheDocument();
|
||||
expect(getByText('Has subcomponents')).toBeInTheDocument();
|
||||
expect(
|
||||
getByText(/No subcomponent is part of this component/i),
|
||||
).toBeInTheDocument();
|
||||
@@ -114,7 +114,7 @@ describe('<HasSubcomponentsCard />', () => {
|
||||
);
|
||||
|
||||
await waitFor(() => {
|
||||
expect(getByText('Subcomponents')).toBeInTheDocument();
|
||||
expect(getByText('Has subcomponents')).toBeInTheDocument();
|
||||
expect(getByText(/target-name/i)).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -30,7 +30,7 @@ export const HasSubcomponentsCard = ({ variant = 'gridItem' }: Props) => {
|
||||
return (
|
||||
<RelatedEntitiesCard
|
||||
variant={variant}
|
||||
title="Subcomponents"
|
||||
title="Has subcomponents"
|
||||
entityKind="Component"
|
||||
relationType={RELATION_HAS_PART}
|
||||
columns={componentEntityColumns}
|
||||
|
||||
@@ -66,7 +66,7 @@ describe('<HasSystemsCard />', () => {
|
||||
</Wrapper>,
|
||||
);
|
||||
|
||||
expect(getByText('Systems')).toBeInTheDocument();
|
||||
expect(getByText('Has systems')).toBeInTheDocument();
|
||||
expect(getByText(/No system is part of this domain/i)).toBeInTheDocument();
|
||||
});
|
||||
|
||||
@@ -112,7 +112,7 @@ describe('<HasSystemsCard />', () => {
|
||||
);
|
||||
|
||||
await waitFor(() => {
|
||||
expect(getByText('Systems')).toBeInTheDocument();
|
||||
expect(getByText('Has systems')).toBeInTheDocument();
|
||||
expect(getByText(/target-name/i)).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -31,7 +31,7 @@ export const HasSystemsCard = ({ variant = 'gridItem' }: Props) => {
|
||||
return (
|
||||
<RelatedEntitiesCard
|
||||
variant={variant}
|
||||
title="Systems"
|
||||
title="Has systems"
|
||||
entityKind="System"
|
||||
relationType={RELATION_HAS_PART}
|
||||
columns={systemEntityColumns}
|
||||
|
||||
Reference in New Issue
Block a user