Skip to content
Browse files
Use a String instead of building one.
  • Loading branch information
garydgregory committed Nov 21, 2020
1 parent ffb85ec commit f2cb1a38ee9e2cfd1ffb17abf2d1ca27c21c7249
Showing 1 changed file with 2 additions and 2 deletions.
@@ -250,8 +250,8 @@ public void testGetBigIntegerIncompatibleType()
public void testGetString()
config.setProperty("testString", "The quick brown fox");
final String string = new String("The quick brown fox");
final String defaultValue = new String("jumps over the lazy dog");
final String string = "The quick brown fox";
final String defaultValue = "jumps over the lazy dog";

assertEquals("Existing key", string, config.getString("testString"));
assertEquals("Existing key with default value", string, config.getString("testString", defaultValue));

0 comments on commit f2cb1a3

Please sign in to comment.