Skip to content
This repository has been archived by the owner on Sep 30, 2024. It is now read-only.

Commit

Permalink
adjust test to account for simpler layout.
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonhawkharris committed Apr 17, 2024
1 parent 0f0b041 commit 6cd61ab
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ const render = () => (
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -153,7 +153,7 @@ const render = () => (
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -190,7 +190,7 @@ const render = () => (
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -237,7 +237,7 @@ const render = () => (
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -286,7 +286,7 @@ const render = () => (
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export const Popover: StoryFn = () => {
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -73,7 +73,7 @@ export const Popover: StoryFn = () => {
query=""
progress={progress}
telemetryService={NOOP_TELEMETRY_SERVICE}
onSearchAgain={() => {}}
onSearchAgain={() => { }}
/>
)}
</BrandedStory>
Expand All @@ -87,7 +87,7 @@ export const ShouldCloseAllInfo: StoryFn = () => {
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: 'By default we exclude forked repositories. Include them with `fork:yes` in your query.',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down Expand Up @@ -116,7 +116,7 @@ export const ShouldCloseAllInfo: StoryFn = () => {
query=""
progress={progress}
telemetryService={NOOP_TELEMETRY_SERVICE}
onSearchAgain={() => {}}
onSearchAgain={() => { }}
/>
)}
</BrandedStory>
Expand All @@ -132,7 +132,7 @@ export const ShouldOpenOneInfo: StoryFn = () => {
repositoriesCount: 2,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: 'By default we exclude forked repositories. Include them with `fork:yes` in your query.',
severity: 'info',
title: '10k forked repositories excluded',
Expand All @@ -151,7 +151,7 @@ export const ShouldOpenOneInfo: StoryFn = () => {
query=""
progress={progress}
telemetryService={NOOP_TELEMETRY_SERVICE}
onSearchAgain={() => {}}
onSearchAgain={() => { }}
/>
)}
</BrandedStory>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
skipped: [
{
reason: 'shard-timedout',
title: 'Internal server error',
title: 'NOT FOUND',
message: 'There was an error',
severity: 'error',
suggested: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,8 @@ describe('SuggestedAction.svelte', () => {
state: 'complete',
})

const title = document.getElementsByClassName('info-badge')
expect(title).toHaveLength(1)

const interpunct = document.getElementsByClassName('separator')
expect(interpunct).toHaveLength(1)

const action = document.getElementsByClassName('action-badge')
expect(action).toHaveLength(1)
const infoBadge = document.getElementsByClassName('info-badge')
expect(infoBadge).toHaveLength(1)
})

test('renders title only when there is no suggested items', async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export const ProgressWithWarning: StoryFn = () => {
matchCount: MULTIPLE_SEARCH_RESULT.progress.matchCount,
skipped: [
{
reason: 'excluded-fork',
reason: 'repository-fork',
message: '10k forked repositories excluded',
severity: 'info',
title: '10k forked repositories excluded',
Expand Down

0 comments on commit 6cd61ab

Please sign in to comment.