[BAEL-12899] - Splitted the java-strings module (#7410)

This commit is contained in:
Amit Pandey
2019-08-02 10:14:32 +05:30
committed by Josh Cummings
parent 87ba90d455
commit ec46f6de26
76 changed files with 212 additions and 66 deletions

View File

@@ -0,0 +1,17 @@
package com.baeldung.string.interview;
import static org.junit.Assert.assertEquals;
import java.util.Arrays;
import org.junit.Test;
public class StringToCharArrayUnitTest {
@Test
public void whenConvertingStringToCharArray_thenConversionSuccessful() {
String beforeConvStr = "hello";
char[] afterConvCharArr = { 'h', 'e', 'l', 'l', 'o' };
assertEquals(Arrays.equals(beforeConvStr.toCharArray(), afterConvCharArr), true);
}
}