📍Use lombok, reformat, and optimize the code (#1560)
* Use lombok, reformat, and optimize the code * Fix merge conflicts and some sonar issues Co-authored-by: va1m <va1m@email.com>
This commit is contained in:
@ -27,6 +27,7 @@ import static com.github.stefanbirkner.systemlambda.SystemLambda.tapSystemOutNor
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import com.github.stefanbirkner.systemlambda.Statement;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
/**
|
||||
@ -55,7 +56,7 @@ class GroundDiveTest {
|
||||
void testSpawnParticles() throws Exception {
|
||||
var groundDive = new GroundDive();
|
||||
final var outputLog = getLogContent(
|
||||
() -> groundDive.spawnParticles("PARTICLE_TYPE", 100));
|
||||
() -> groundDive.spawnParticles("PARTICLE_TYPE", 100));
|
||||
final var expectedLog = "Spawn 100 particle with type PARTICLE_TYPE";
|
||||
assertEquals(outputLog, expectedLog);
|
||||
}
|
||||
@ -64,7 +65,7 @@ class GroundDiveTest {
|
||||
void testActivate() throws Exception {
|
||||
var groundDive = new GroundDive();
|
||||
var logs = tapSystemOutNormalized(groundDive::activate)
|
||||
.split("\n");
|
||||
.split("\n");
|
||||
final var expectedSize = 3;
|
||||
final var log1 = logs[0].split("-")[1].trim() + " -" + logs[0].split("-")[2].trim();
|
||||
final var expectedLog1 = "Move to ( 0.0, 0.0, -20.0 )";
|
||||
|
@ -54,7 +54,7 @@ class SkyLaunchTest {
|
||||
void testSpawnParticles() throws Exception {
|
||||
var skyLaunch = new SkyLaunch();
|
||||
var outputLog = getLogContent(
|
||||
() -> skyLaunch.spawnParticles("PARTICLE_TYPE", 100));
|
||||
() -> skyLaunch.spawnParticles("PARTICLE_TYPE", 100));
|
||||
var expectedLog = "Spawn 100 particle with type PARTICLE_TYPE";
|
||||
assertEquals(outputLog, expectedLog);
|
||||
}
|
||||
@ -63,7 +63,7 @@ class SkyLaunchTest {
|
||||
void testActivate() throws Exception {
|
||||
var skyLaunch = new SkyLaunch();
|
||||
var logs = tapSystemOutNormalized(skyLaunch::activate)
|
||||
.split("\n");
|
||||
.split("\n");
|
||||
final var expectedSize = 3;
|
||||
final var log1 = getLogContent(logs[0]);
|
||||
final var expectedLog1 = "Move to ( 0.0, 0.0, 20.0 )";
|
||||
|
Reference in New Issue
Block a user