Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw

* 'master' of github.com:spotify/backstage: (139 commits)
  Cleanup
  Update PinButton.test.tsx
  feat: update github insights plugin version (#2973)
  Ignore IntelliJ *.iml files (#2971)
  chore(deps): bump rollup-plugin-dts from 1.4.11 to 1.4.13
  fix the plugin card on plugins page
  align 'Add to Marketplace' button on plugins page
  fix the PluginGrid on mobiles sizes
  use getBy query instead of queryBy when asserting for elements present in document (#2951)
  Update PinButton.tsx
  Add test case for Progress component (#2953)
  fix the styling of footer copy on mobile
  add changeset
  handle the case where no entities are available to show
  core-api: work around issue with ApiRef export const declarations
  core-api: move utility api system implementation into apis/system
  Update docs regarding npm config ignore-scripts flag
  Another try
  Fix Core Features configuration id (#2948)
  Fix test?
  ...
This commit is contained in:
blam
2020-10-19 23:57:40 +02:00
332 changed files with 4838 additions and 2569 deletions
@@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import React, { useState, useMemo, FC, ReactNode } from 'react';
import { useLocalStorage, useAsync } from 'react-use';
import { useNavigate } from 'react-router-dom';
@@ -28,7 +27,6 @@ import {
ContentHeader,
HeaderLabel,
Progress,
pageTheme,
useApi,
} from '@backstage/core';
@@ -95,7 +93,7 @@ const AuditList: FC<{}> = () => {
}
return (
<Page theme={pageTheme.tool}>
<Page themeId="tool">
<Header
title="Lighthouse"
subtitle="Website audits powered by Lighthouse"
@@ -120,7 +118,7 @@ const AuditList: FC<{}> = () => {
</ContentHeader>
<Grid container spacing={3} direction="column">
<Grid item>
<InfoCard>{content}</InfoCard>
<InfoCard noPadding>{content}</InfoCard>
</Grid>
</Grid>
</Content>
@@ -163,7 +163,7 @@ describe('AuditView', () => {
});
describe('when the request for the website by id is pending', () => {
it('it shows the loading', async () => {
it('shows the loading', async () => {
mockFetch.mockImplementationOnce(() => new Promise(() => {}));
const rendered = render(
wrapInTestApp(
@@ -177,7 +177,7 @@ describe('AuditView', () => {
});
describe('when the request for the website by id fails', () => {
it('it shows an error', async () => {
it('shows an error', async () => {
mockFetch.mockRejectOnce(new Error('failed to fetch'));
const rendered = render(
wrapInTestApp(
@@ -34,7 +34,6 @@ import {
import Alert from '@material-ui/lab/Alert';
import {
useApi,
pageTheme,
InfoCard,
Header,
Page,
@@ -193,7 +192,7 @@ export const AuditViewContent: FC<{}> = () => {
};
const ConnectedAuditView = () => (
<Page theme={pageTheme.tool}>
<Page themeId="tool">
<Header title="Lighthouse" subtitle="Website audits powered by Lighthouse">
<HeaderLabel label="Owner" value="Spotify" />
<HeaderLabel label="Lifecycle" value="Alpha" />
@@ -30,7 +30,6 @@ import {
InfoCard,
Header,
Page,
pageTheme,
Content,
ContentHeader,
HeaderLabel,
@@ -170,7 +169,7 @@ export const CreateAuditContent: FC<{}> = () => {
};
const CreateAudit = () => (
<Page theme={pageTheme.tool}>
<Page themeId="tool">
<Header title="Lighthouse" subtitle="Website audits powered by Lighthouse">
<HeaderLabel label="Owner" value="Spotify" />
<HeaderLabel label="Lifecycle" value="Alpha" />
@@ -75,7 +75,7 @@ describe('useWebsiteForEntity', () => {
(mockLighthouseApi.getWebsiteByUrl as jest.Mock).mockResolvedValue(website);
});
it('returns the lighthouse information for the website url in annotations ', async () => {
it('returns the lighthouse information for the website url in annotations', async () => {
const { result, waitForNextUpdate } = subject();
await waitForNextUpdate();
expect(result.current?.value).toBe(website);