-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #291 from nulib/deploy/staging
Production push
- Loading branch information
Showing
32 changed files
with
1,914 additions
and
12,482 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
nodejs 16.14.0 | ||
nodejs 20.5.0 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
|
||
const SliderWrapperMock = ({ collectionId }: { collectionId: string }) => ( | ||
<div>Mock SliderWrapper with props: {collectionId}</div> | ||
); | ||
|
||
export default SliderWrapperMock; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import React from "react"; | ||
const ViewerWrapperMock = () => <div>Mock ViewerWrapper</div>; | ||
|
||
export default ViewerWrapperMock; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,36 @@ | ||
import RelatedItems, { | ||
RelatedItemsProps, | ||
} from "@/components/Shared/RelatedItems"; | ||
import { render, screen, waitFor } from "@/test-utils"; | ||
import { render, screen } from "@/test-utils"; | ||
|
||
jest.mock("../Clover/SliderWrapper.tsx"); | ||
|
||
const props: RelatedItemsProps = { | ||
collectionUris: ["http://localhost:3000/something.json"], | ||
title: "Explore Further", | ||
}; | ||
|
||
xdescribe("RelatedItems component", () => { | ||
it("renders a wrapping element for Clover", async () => { | ||
describe("RelatedItems component", () => { | ||
it("renders the component and proper heading", async () => { | ||
render(<RelatedItems {...props} />); | ||
await waitFor(() => { | ||
expect(screen.getByTestId("related-items")).toBeInTheDocument; | ||
}); | ||
await waitFor(() => { | ||
expect(screen.getByRole("heading", { level: 2 })).toHaveTextContent( | ||
"Explore Further" | ||
); | ||
}); | ||
expect(await screen.findByTestId("related-items")).toBeInTheDocument(); | ||
expect(await screen.findByRole("heading", { level: 2 })).toHaveTextContent( | ||
"Explore Further" | ||
); | ||
}); | ||
|
||
it("renders multiple SliderWrappers if passed multiple Collection URIs", async () => { | ||
const multipleUris = { | ||
collectionUris: [ | ||
"http://localhost:3000/something", | ||
"http://localhost:3000/another-thing", | ||
], | ||
title: "Multiple Related Items", | ||
}; | ||
|
||
render(<RelatedItems {...multipleUris} />); | ||
for (const uri of multipleUris.collectionUris) { | ||
expect(await screen.findByText(uri, { exact: false })); | ||
} | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.