1 package de.dlr.shepard.common.exceptions;
2
3 import static org.junit.jupiter.api.Assertions.assertEquals;
4
5 import org.junit.jupiter.api.Test;
6
7 public class InvalidAuthExceptionTest {
8
9 @Test
10 public void testDefaultConstructor() {
11 var obj = new InvalidAuthException();
12 assertEquals("Invalid authentication or authorization", obj.getMessage());
13 }
14
15 @Test
16 public void testConstructor() {
17 var obj = new InvalidAuthException("Message");
18 assertEquals("Message", obj.getMessage());
19 }
20
21 @Test
22 public void testGetStatusCode() {
23 var obj = new InvalidAuthException();
24 assertEquals(403, obj.getResponse().getStatus());
25 }
26 }