Files
CipherStreamAPI/src/test/java/com/mattrixwv/cipherstream/aspect/CipherStreamLoggingAspectTest.java
2024-04-28 15:26:40 -04:00

51 lines
986 B
Java

package com.mattrixwv.cipherstream.aspect;
import static org.junit.jupiter.api.Assertions.*;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.mockito.InjectMocks;
import org.mockito.junit.jupiter.MockitoExtension;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.node.ObjectNode;
@Tag("unit-test")
@ExtendWith(MockitoExtension.class)
public class CipherStreamLoggingAspectTest{
@InjectMocks
private CipherStreamLoggingAspect aspect;
@Test
public void testMappedFunction(){
aspect.mappedFunction();
assertNotNull(aspect);
}
@Test
public void testCipherMethod(){
aspect.cipherMethod();
assertNotNull(aspect);
}
@Test
public void testGetCipherInfo(){
ObjectNode jsonNode = new ObjectMapper().createObjectNode();
jsonNode.put("something", "Something Important");
aspect.getCipherInfo(jsonNode);
assertNotNull(aspect);
}
}