Skip to content

Commit

Permalink
Add caching back
Browse files Browse the repository at this point in the history
  • Loading branch information
Pelayori committed Apr 1, 2024
1 parent 4660041 commit ea7c03b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
1 change: 0 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,6 @@
<phase>verify</phase>
<goals>
<goal>merge</goal>
<goal>report-aggregate</goal>
</goals>
<configuration>
<fileSets>
Expand Down
18 changes: 12 additions & 6 deletions src/test/java/com/uniovi/Wiq_UnitTests.java
Original file line number Diff line number Diff line change
@@ -1,23 +1,29 @@
package com.uniovi;

import org.junit.jupiter.api.MethodOrderer;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestMethodOrder;
import com.uniovi.entities.Player;
import com.uniovi.services.PlayerService;
import org.junit.jupiter.api.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.annotation.DirtiesContext;
import org.springframework.test.context.ActiveProfiles;

import java.util.Optional;

@SpringBootTest
@Tag("unit")
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD)
@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
@ActiveProfiles("test")
public class Wiq_UnitTests {

@Test
public void contextLoads() {
@Autowired
private PlayerService playerService;

@Test
public void testPlayerService() {
Optional<Player> player = playerService.getUser(1L);
Assertions.assertTrue(player.isPresent());
}

}

0 comments on commit ea7c03b

Please sign in to comment.