From 1c2cbf0e75abd7d8f278bfbefffa7cac951bd2d1 Mon Sep 17 00:00:00 2001 From: Paul Schaub Date: Sun, 9 Jan 2022 02:02:04 +0100 Subject: [PATCH] Add SigningResultTest --- .../test/java/sop/util/SigningResultTest.java | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 sop-java/src/test/java/sop/util/SigningResultTest.java diff --git a/sop-java/src/test/java/sop/util/SigningResultTest.java b/sop-java/src/test/java/sop/util/SigningResultTest.java new file mode 100644 index 00000000..0d35cdc1 --- /dev/null +++ b/sop-java/src/test/java/sop/util/SigningResultTest.java @@ -0,0 +1,23 @@ +// SPDX-FileCopyrightText: 2022 Paul Schaub +// +// SPDX-License-Identifier: Apache-2.0 + +package sop.util; + +import static org.junit.jupiter.api.Assertions.assertEquals; + +import org.junit.jupiter.api.Test; +import sop.MicAlg; +import sop.SigningResult; + +public class SigningResultTest { + + @Test + public void basicBuilderTest() { + SigningResult result = SigningResult.builder() + .setMicAlg(MicAlg.fromHashAlgorithmId(10)) + .build(); + + assertEquals("pgp-sha512", result.getMicAlg().getMicAlg()); + } +}