BAEL-4399: Changes for removing tab spaces
This commit is contained in:
parent
3bea743e5b
commit
e13f7952b1
@ -1,6 +1,8 @@
|
|||||||
package com.baeldung.exceptions.nosuchfielderror;
|
package com.baeldung.exceptions.nosuchfielderror;
|
||||||
|
|
||||||
public class Dependent {
|
public class Dependent {
|
||||||
|
|
||||||
// This needed to be commented post compilation of NoSuchFielDError and Compile
|
// This needed to be commented post compilation of NoSuchFielDError and Compile
|
||||||
public static String message = "Hello Baeldung!!";
|
public static String message = "Hello Baeldung!!";
|
||||||
|
|
||||||
}
|
}
|
@ -3,14 +3,18 @@ package com.baeldung.exceptions.nosuchfielderror;
|
|||||||
public class FieldErrorExample {
|
public class FieldErrorExample {
|
||||||
|
|
||||||
public static void main(String... args) {
|
public static void main(String... args) {
|
||||||
|
|
||||||
fetchAndPrint();
|
fetchAndPrint();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String getDependentMessage() {
|
public static String getDependentMessage() {
|
||||||
|
|
||||||
return Dependent.message;
|
return Dependent.message;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void fetchAndPrint() {
|
public static void fetchAndPrint() {
|
||||||
|
|
||||||
System.out.println(getDependentMessage());
|
System.out.println(getDependentMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -8,7 +8,9 @@ public class FieldErrorExampleUnitTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void whenDependentMessage_returnMessage() {
|
public void whenDependentMessage_returnMessage() {
|
||||||
|
|
||||||
String dependentMessage = FieldErrorExample.getDependentMessage();
|
String dependentMessage = FieldErrorExample.getDependentMessage();
|
||||||
assertTrue("Hello Baeldung!!".equals(dependentMessage));
|
assertTrue("Hello Baeldung!!".equals(dependentMessage));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user