|
|
@ -0,0 +1,33 @@ |
|
|
|
package device.usbPlayer; |
|
|
|
|
|
|
|
import org.junit.jupiter.params.ParameterizedTest; |
|
|
|
import org.junit.jupiter.params.provider.Arguments; |
|
|
|
import org.junit.jupiter.params.provider.MethodSource; |
|
|
|
|
|
|
|
import java.util.stream.Stream; |
|
|
|
import java.util.ArrayList; |
|
|
|
|
|
|
|
import static org.assertj.core.api.Assertions.assertThat; |
|
|
|
|
|
|
|
class USB_StickTest { |
|
|
|
|
|
|
|
@ParameterizedTest |
|
|
|
@MethodSource("getAlbumOptions") |
|
|
|
void getAlbumTest(String testName, ArrayList<String> album,int TestNr) {//, int expectedResult |
|
|
|
//int volumeNum = inputPlay.getLautstaerke(); |
|
|
|
if(TestNr == 1) |
|
|
|
assertThat(album).describedAs(testName).isNotEmpty(); |
|
|
|
} |
|
|
|
|
|
|
|
static Stream<Arguments> getAlbumOptions() { |
|
|
|
USB_Stick stick = new USB_Stick(); |
|
|
|
ArrayList<String> AlbumsItems = new ArrayList<>(); |
|
|
|
AlbumsItems= stick.getAlbum(); |
|
|
|
|
|
|
|
|
|
|
|
return Stream.of( |
|
|
|
Arguments.of("First Album is loaded", stick.getAlbum(),1)//,something |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|
} |