Skip to content

Commit 3209e35

Browse files
committed
Cleanup unit tests
1 parent 2de33c0 commit 3209e35

File tree

11 files changed

+43
-48
lines changed

11 files changed

+43
-48
lines changed

src/test/java/com/github/vbauer/avconv4java/common/TestUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ private TestUtils() {
1313
}
1414

1515

16-
public static void checkUtilClassConstructor(final Class<?> utilsClass) throws Throwable {
16+
public static void checkUtilClassConstructor(final Class<?> utilsClass) {
1717
PrivateConstructorChecker.forClass(utilsClass)
1818
.expectedTypeOfException(UnsupportedOperationException.class)
1919
.check();

src/test/java/com/github/vbauer/avconv4java/core/AVRootOptionsTest.java

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
package com.github.vbauer.avconv4java.core;
22

3-
import java.util.List;
4-
53
import org.testng.annotations.Test;
64
import org.testng.collections.Lists;
5+
6+
import java.util.List;
7+
78
import static org.hamcrest.MatcherAssert.assertThat;
8-
import static org.hamcrest.Matchers.emptyIterable;
9-
import static org.hamcrest.Matchers.equalTo;
10-
import static org.hamcrest.Matchers.not;
9+
import static org.hamcrest.Matchers.*;
1110

1211
/**
1312
* @author Vladislav Bauer
@@ -22,7 +21,7 @@ public class AVRootOptionsTest {
2221
@Test
2322
public void testSmokeAVRootOptions() {
2423
final AVRootOptions rootOptions = AVRootOptions.create(INPUT_FILE, OUTPUT_FILE)
25-
.builders(Lists.<AVOptions>newArrayList())
24+
.builders(Lists.newArrayList())
2625
.builders()
2726
.flags(Lists.newArrayList())
2827
.flags();

src/test/java/com/github/vbauer/avconv4java/option/AVAudioOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVAudioCodecType;
74
import com.github.vbauer.avconv4java.type.AVStreamType;
85
import org.testng.annotations.Test;
96
import org.testng.collections.Lists;
7+
8+
import java.util.List;
9+
1010
import static org.hamcrest.MatcherAssert.assertThat;
1111
import static org.hamcrest.Matchers.emptyIterable;
1212
import static org.hamcrest.Matchers.not;
@@ -34,7 +34,7 @@ public void testSmokeAVAudioOptions() {
3434
.sampleFormat("format")
3535
.sampleRate(AVStreamType.AUDIO, 1)
3636
.sampleRate(1)
37-
.builders(Lists.<AVOptions>newArrayList())
37+
.builders(Lists.newArrayList())
3838
.builders()
3939
.flags(Lists.newArrayList())
4040
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVCodecOptionsTest.java

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
6-
import com.github.vbauer.avconv4java.type.AVCodecFlagType;
7-
import com.github.vbauer.avconv4java.type.AVDebugInfoType;
8-
import com.github.vbauer.avconv4java.type.AVMotionEstimationType;
9-
import com.github.vbauer.avconv4java.type.AVStreamType;
10-
import com.github.vbauer.avconv4java.type.AVStrictType;
3+
import com.github.vbauer.avconv4java.type.*;
114
import org.testng.annotations.Test;
125
import org.testng.collections.Lists;
6+
7+
import java.util.List;
8+
139
import static org.hamcrest.MatcherAssert.assertThat;
1410
import static org.hamcrest.Matchers.emptyIterable;
1511
import static org.hamcrest.Matchers.not;
@@ -46,7 +42,7 @@ public void testSmokeAVCodecOptions() {
4642
.strict(AVStrictType.STRICT.getName())
4743
.videoBitRateTolerance(AVStreamType.AUDIO, 1)
4844
.videoBitRateTolerance(1)
49-
.builders(Lists.<AVOptions>newArrayList())
45+
.builders(Lists.newArrayList())
5046
.builders()
5147
.flags(Lists.newArrayList())
5248
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVFormatOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVErrorDetectionType;
74
import com.github.vbauer.avconv4java.type.AVFormatDebugInfoType;
85
import com.github.vbauer.avconv4java.type.AVFormatFlagType;
96
import org.testng.annotations.Test;
107
import org.testng.collections.Lists;
8+
9+
import java.util.List;
10+
1111
import static org.hamcrest.MatcherAssert.assertThat;
1212
import static org.hamcrest.Matchers.emptyIterable;
1313
import static org.hamcrest.Matchers.not;
@@ -36,7 +36,7 @@ public void testSmokeAVFormatOptions() {
3636
.probeSize(1L)
3737
.realTimeBufferSize(1L)
3838
.timestampIndexSize(1L)
39-
.builders(Lists.<AVOptions>newArrayList())
39+
.builders(Lists.newArrayList())
4040
.builders()
4141
.flags(Lists.newArrayList())
4242
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVGenericOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVLogLevelType;
74
import org.testng.annotations.Test;
85
import org.testng.collections.Lists;
6+
7+
import java.util.List;
8+
99
import static org.hamcrest.MatcherAssert.assertThat;
1010
import static org.hamcrest.Matchers.emptyIterable;
1111
import static org.hamcrest.Matchers.not;
@@ -24,7 +24,7 @@ public void testSmokeAVGenericOptions() {
2424
.logLevel(AVLogLevelType.DEBUG)
2525
.logLevel(AVLogLevelType.DEBUG.getName())
2626
.showLicense()
27-
.builders(Lists.<AVOptions>newArrayList())
27+
.builders(Lists.newArrayList())
2828
.builders()
2929
.flags(Lists.newArrayList())
3030
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVMainOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVFileFormatType;
74
import com.github.vbauer.avconv4java.type.AVStreamType;
85
import com.github.vbauer.avconv4java.type.AVTargetFileType;
96
import org.testng.annotations.Test;
107
import org.testng.collections.Lists;
8+
9+
import java.util.List;
10+
1111
import static org.hamcrest.MatcherAssert.assertThat;
1212
import static org.hamcrest.Matchers.emptyIterable;
1313
import static org.hamcrest.Matchers.not;
@@ -49,7 +49,7 @@ public void testSmokeAVMainOptions() {
4949
.seek("position")
5050
.target(AVTargetFileType.DV)
5151
.target(AVTargetFileType.DV.getName())
52-
.builders(Lists.<AVOptions>newArrayList())
52+
.builders(Lists.newArrayList())
5353
.builders()
5454
.flags(Lists.newArrayList())
5555
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVSubtitleOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import org.testng.annotations.Test;
74
import org.testng.collections.Lists;
5+
6+
import java.util.List;
7+
88
import static org.hamcrest.MatcherAssert.assertThat;
99
import static org.hamcrest.Matchers.emptyIterable;
1010
import static org.hamcrest.Matchers.not;
@@ -20,7 +20,7 @@ public void testSmokeAVSubtitleOptions() {
2020
final List<String> options = AVSubtitleOptions.create()
2121
.disableRecording()
2222
.subtitleCodec("codecName")
23-
.builders(Lists.<AVOptions>newArrayList())
23+
.builders(Lists.newArrayList())
2424
.builders()
2525
.flags(Lists.newArrayList())
2626
.flags()

src/test/java/com/github/vbauer/avconv4java/option/AVVideoOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
package com.github.vbauer.avconv4java.option;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVMovFlagsType;
74
import com.github.vbauer.avconv4java.type.AVStreamType;
85
import com.github.vbauer.avconv4java.type.AVVideoCodecType;
96
import com.github.vbauer.avconv4java.type.AVVideoSizeType;
107
import org.testng.annotations.Test;
118
import org.testng.collections.Lists;
9+
10+
import java.util.List;
11+
1212
import static org.hamcrest.MatcherAssert.assertThat;
1313
import static org.hamcrest.Matchers.emptyIterable;
1414
import static org.hamcrest.Matchers.not;
@@ -50,7 +50,7 @@ public void testSmokeAVVideoOptions() {
5050
.twoPassEncoding(AVStreamType.AUDIO)
5151
.videoCodec(AVVideoCodecType.H264)
5252
.videoCodec(AVVideoCodecType.H264.getName())
53-
.builders(Lists.<AVOptions>newArrayList())
53+
.builders(Lists.newArrayList())
5454
.builders()
5555
.flags(Lists.newArrayList())
5656
.flags()

src/test/java/com/github/vbauer/avconv4java/option/advanced/AVAdvancedOptionsTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
package com.github.vbauer.avconv4java.option.advanced;
22

3-
import java.util.List;
4-
5-
import com.github.vbauer.avconv4java.core.AVOptions;
63
import com.github.vbauer.avconv4java.type.AVVideoSyncType;
74
import org.testng.annotations.Test;
85
import org.testng.collections.Lists;
6+
7+
import java.util.List;
8+
99
import static org.hamcrest.MatcherAssert.assertThat;
1010
import static org.hamcrest.Matchers.emptyIterable;
1111
import static org.hamcrest.Matchers.not;
@@ -33,7 +33,7 @@ public void testSmokeAVAdvancedOptions() {
3333
.timeLimit(1L)
3434
.videoSyncMethod(AVVideoSyncType.AUTO)
3535
.videoSyncMethod(AVVideoSyncType.AUTO.getName())
36-
.builders(Lists.<AVOptions>newArrayList())
36+
.builders(Lists.newArrayList())
3737
.builders()
3838
.flags(Lists.newArrayList())
3939
.flags()

0 commit comments

Comments
 (0)