📍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:
@ -35,7 +35,7 @@ import org.junit.jupiter.api.Test;
|
||||
public class FileLoaderTest {
|
||||
|
||||
@Test
|
||||
public void testLoadData() {
|
||||
void testLoadData() {
|
||||
final var fileLoader = new FileLoader();
|
||||
fileLoader.setFileName("non-existing-file");
|
||||
assertNull(fileLoader.loadData());
|
||||
|
@ -67,7 +67,7 @@ public class FileSelectorPresenterTest {
|
||||
* Tests if the Presenter was successfully connected with the View.
|
||||
*/
|
||||
@Test
|
||||
public void wiring() {
|
||||
void wiring() {
|
||||
presenter.start();
|
||||
|
||||
assertNotNull(stub.getPresenter());
|
||||
@ -78,7 +78,7 @@ public class FileSelectorPresenterTest {
|
||||
* Tests if the name of the file changes.
|
||||
*/
|
||||
@Test
|
||||
public void updateFileNameToLoader() {
|
||||
void updateFileNameToLoader() {
|
||||
var expectedFile = "Stamatis";
|
||||
stub.setFileName(expectedFile);
|
||||
|
||||
@ -93,7 +93,7 @@ public class FileSelectorPresenterTest {
|
||||
* empty string.
|
||||
*/
|
||||
@Test
|
||||
public void fileConfirmationWhenNameIsNull() {
|
||||
void fileConfirmationWhenNameIsNull() {
|
||||
stub.setFileName(null);
|
||||
|
||||
presenter.start();
|
||||
@ -108,7 +108,7 @@ public class FileSelectorPresenterTest {
|
||||
* Tests if we receive a confirmation when we attempt to open a file that it doesn't exist.
|
||||
*/
|
||||
@Test
|
||||
public void fileConfirmationWhenFileDoesNotExist() {
|
||||
void fileConfirmationWhenFileDoesNotExist() {
|
||||
stub.setFileName("RandomName.txt");
|
||||
|
||||
presenter.start();
|
||||
@ -123,7 +123,7 @@ public class FileSelectorPresenterTest {
|
||||
* Tests if we can open the file, when it exists.
|
||||
*/
|
||||
@Test
|
||||
public void fileConfirmationWhenFileExists() {
|
||||
void fileConfirmationWhenFileExists() {
|
||||
stub.setFileName("etc/data/test.txt");
|
||||
presenter.start();
|
||||
presenter.fileNameChanged();
|
||||
@ -137,7 +137,7 @@ public class FileSelectorPresenterTest {
|
||||
* Tests if the view closes after cancellation.
|
||||
*/
|
||||
@Test
|
||||
public void cancellation() {
|
||||
void cancellation() {
|
||||
presenter.start();
|
||||
presenter.cancelled();
|
||||
|
||||
|
Reference in New Issue
Block a user