renders correctly 1`] = `
|
+ >
+ Text
+
diff --git a/src/components/TemurinArchiveTable/index.tsx b/src/components/TemurinArchiveTable/index.tsx
index 8c779f83d..11b340df8 100644
--- a/src/components/TemurinArchiveTable/index.tsx
+++ b/src/components/TemurinArchiveTable/index.tsx
@@ -88,9 +88,9 @@ const TemurinArchiveTable = ({results, updatePage}) => {
}
|
- {asset.installer_link ? (
- Checksum
- ): <>>
+ {asset.installer_link && asset.installer_checksum
+ ? Checksum
+ : Not available
}
|
@@ -105,7 +105,10 @@ const TemurinArchiveTable = ({results, updatePage}) => {
/>
|
- Checksum
+ {asset.checksum
+ ? Checksum
+ : Not available
+ }
|
)
diff --git a/src/components/TemurinDownloadTable/__tests__/TemurinDownloadTable.test.tsx b/src/components/TemurinDownloadTable/__tests__/TemurinDownloadTable.test.tsx
index 450a5ced8..23287e0a1 100644
--- a/src/components/TemurinDownloadTable/__tests__/TemurinDownloadTable.test.tsx
+++ b/src/components/TemurinDownloadTable/__tests__/TemurinDownloadTable.test.tsx
@@ -44,4 +44,20 @@ describe('TemurinDownloadTable component', () => {
);
expect(container).toMatchSnapshot();
});
+
+ it('renders correctly - Without checksum', () => {
+ let releases = [
+ createRandomTemurinRelease(true),
+ ];
+
+ // erase checksum
+ releases[0].binaries[0].checksum = undefined;
+
+ const { container } = render(
+
+ );
+ expect(container).toMatchSnapshot();
+ });
});
\ No newline at end of file
diff --git a/src/components/TemurinDownloadTable/__tests__/__snapshots__/TemurinDownloadTable.test.tsx.snap b/src/components/TemurinDownloadTable/__tests__/__snapshots__/TemurinDownloadTable.test.tsx.snap
index ce28c1b05..c8dee94fe 100644
--- a/src/components/TemurinDownloadTable/__tests__/__snapshots__/TemurinDownloadTable.test.tsx.snap
+++ b/src/components/TemurinDownloadTable/__tests__/__snapshots__/TemurinDownloadTable.test.tsx.snap
@@ -1,5 +1,213 @@
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
+exports[`TemurinDownloadTable component > renders correctly - Without checksum 1`] = `
+
+
+
+
+
+
+
+ release_name_mock
+
+
+
+ Temurin
+
+
+
+
+
+
+ January 1, 2020
+
+ |
+
+ Os_mock
+ |
+
+ arch_mock
+ |
+
+
+ |
+
+
+
+
+`;
+
exports[`TemurinDownloadTable component > renders correctly - no data 1`] = `
-
- Checksum
-
+ {checksum
+ ? Checksum
+ : Not available
+ }
|
diff --git a/src/components/TemurinNightlyTable/__tests__/TemurinNightlyTable.test.tsx b/src/components/TemurinNightlyTable/__tests__/TemurinNightlyTable.test.tsx
index eb4038cf8..e1b6d07c4 100644
--- a/src/components/TemurinNightlyTable/__tests__/TemurinNightlyTable.test.tsx
+++ b/src/components/TemurinNightlyTable/__tests__/TemurinNightlyTable.test.tsx
@@ -30,4 +30,23 @@ describe('TemurinNightlyTable component', () => {
);
expect(container).toMatchSnapshot();
});
+
+ it('renders correctly - Without checksum', () => {
+ const data = {
+ pagecount: null,
+ releases: [
+ createRandomTemurinReleases(true),
+ ]
+ }
+
+ // erase checksum
+ data.releases[0].platforms.platform_mock.assets[0].checksum = undefined;
+
+ const { container } = render(
+
+ );
+ expect(container).toMatchSnapshot();
+ });
});
\ No newline at end of file
diff --git a/src/components/TemurinNightlyTable/__tests__/__snapshots__/TemurinNightlyTable.test.tsx.snap b/src/components/TemurinNightlyTable/__tests__/__snapshots__/TemurinNightlyTable.test.tsx.snap
index 8427148cd..995f519fe 100644
--- a/src/components/TemurinNightlyTable/__tests__/__snapshots__/TemurinNightlyTable.test.tsx.snap
+++ b/src/components/TemurinNightlyTable/__tests__/__snapshots__/TemurinNightlyTable.test.tsx.snap
@@ -1,5 +1,103 @@
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
+exports[`TemurinNightlyTable component > renders correctly - Without checksum 1`] = `
+
+
+
+
+
+
+ Platform
+ |
+
+ Type
+ |
+
+ Build/Tag
+ |
+
+ Date
+ |
+
+ Binary
+ |
+
+ Installer
+ |
+
+ SHA256
+ |
+
+
+
+
+
+ Os_mock
+
+ architecture_mock
+ |
+
+ type_mock
+ |
+
+ release_name_mock
+ |
+
+ January 1, 2020
+ |
+
+
+ extension_mock (0 MB)
+
+ |
+
+
+ installer_extension_mock
+
+ |
+
+ Text
+ |
+
+
+
+
+
+`;
+
exports[`TemurinNightlyTable component > renders correctly - no data 1`] = `