Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
uses: lewagon/[email protected]
with:
ref: ${{ github.ref }}
check-name: 'Lint & Test'
check-name: "Lint & Test"
repo-token: ${{ secrets.GITHUB_TOKEN }}

build-prod:
Expand All @@ -46,7 +46,7 @@ jobs:
npm run postexport
env:
# Build-time envs used in next.config.js
NET: 'mainnet'
NET: "mainnet"
INFURA_API_KEY: ${{ secrets.INFURA_API_KEY }}
ALCHEMY_API_KEY: ${{ secrets.ALCHEMY_API_KEY }}
GA4_TAG_ID: ${{ secrets.GA4_TAG_ID }}
Expand Down Expand Up @@ -79,7 +79,7 @@ jobs:
- name: Select target bucket
id: bucket
run: |
echo "bucket=${S3_BUCKET_PROD}" >> $GITHUB_OUTPUT
echo "bucket=${S3_BUCKET_PROD}" >> $GITHUB_OUTPUT
env:
S3_BUCKET_PROD: ${{ secrets.S3_BUCKET_PROD }}

Expand All @@ -102,9 +102,9 @@ jobs:

- name: Invalidate CloudFront
env:
CLOUDFRONT_DISTRIBUTION_ID_PROD: ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID_PROD }}
if: ${{ env.CLOUDFRONT_DISTRIBUTION_ID_PROD != '' }}
CLOUDFRONT_DISTRIBUTION_ID: ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID }}
if: ${{ env.CLOUDFRONT_DISTRIBUTION_ID != '' }}
run: |
aws cloudfront create-invalidation \
--distribution-id ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID_PROD }} \
--distribution-id ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID }} \
--paths "/*"
2 changes: 1 addition & 1 deletion src/components/tests/dns-registry-verified.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const StatusButton = Selector("#certificate-status");
test("Sample document is rendered correctly when dns and registry is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
5 changes: 1 addition & 4 deletions src/components/tests/download-certificate.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,7 @@ test("Sample document with special characters is downloaded correctly", async (t
await enableDownloadForHeadlessChrome(t);
await t.setFilesToUpload("input[type=file]", [Document2]);

await validateTextContent(t, StatusButton, [
"DEMO-OPENCERTS.OPENATTESTATION.COM",
"SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)",
]);
await validateTextContent(t, StatusButton, ["DEMO-OPENCERTS.OPENATTESTATION.COM", "SEPOLIA: OPENCERTS"]);

// Simulate an OpenCert file download
const fileName = await DownloadLink.getAttribute("download");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ test("Load OA v2.0 document from action should work when action is valid (key fr
await t.navigateTo(
`http://localhost:3000/?q=${encodeURI(JSON.stringify(action))}#${encodeURI(JSON.stringify(anchor))}`
);
await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down Expand Up @@ -79,7 +79,7 @@ test("Load document from action should work when action is valid (key from query
};

await t.navigateTo(`http://localhost:3000/?q=${encodeURI(JSON.stringify(action))}`);
await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
2 changes: 1 addition & 1 deletion src/components/tests/load-action-plain-certificate.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ test("Load document from action should work when url is valid (OA v2.0)", async
};

await t.navigateTo(`http://localhost:3000/?q=${encodeURI(JSON.stringify(action))}`);
await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const StatusButton = Selector("#certificate-status");
test("Sample document is rendered correctly when multiple dns is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
2 changes: 1 addition & 1 deletion src/components/tests/multi-dns-verified.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const StatusButton = Selector("#certificate-status");
test("Sample document is rendered correctly when multiple dns is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
2 changes: 1 addition & 1 deletion src/components/tests/multi-registry-verified.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ const StatusButton = Selector("#certificate-status");
test("Sample document is rendered correctly when multiple registry is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);
});
2 changes: 1 addition & 1 deletion src/components/tests/obfuscated-document-verified.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const ObfuscationNote = Selector("#obfuscation-note");
test("Sample document is rendered correctly when single registry is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await validateTextContent(t, ObfuscationNote, [
"The owner of this certificate have chosen not to share certain information in the certificate with you. Please note that this does not affect the authenticity of the certificate.",
Expand Down
2 changes: 1 addition & 1 deletion src/components/tests/registry-verified.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const SampleTemplate = Selector("#rendered-certificate");
test("Sample document is rendered correctly when single registry is verified", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
2 changes: 1 addition & 1 deletion src/components/tests/verified-unverified-issuer.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const StatusButton = Selector("#certificate-status");
test("Sample doc is rendered correctly when any one of dns or registry is verified and doc store mismatch in domain", async (t) => {
await t.setFilesToUpload("input[type=file]", [Document]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down
2 changes: 1 addition & 1 deletion src/sagas/sagatests/integration-server-error.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ test.requestHooks(badGatewayMockInfuraOnly)(
async (t) => {
await t.setFilesToUpload("input[type=file]", [Certificate2]);

await validateTextContent(t, StatusButton, ["SEPOLIA: GOVERNMENT TECHNOLOGY AGENCY OF SINGAPORE (GOVTECH)"]);
await validateTextContent(t, StatusButton, ["SEPOLIA: OPENCERTS"]);

await t.switchToIframe(IframeBlock);

Expand Down