Skip to content
This repository was archived by the owner on Mar 25, 2025. It is now read-only.

Commit ff39e04

Browse files
slu-itAxel Schüssler
authored andcommitted
Fixed Java and JavaDoc compiler issues
1 parent 82aa6dd commit ff39e04

File tree

11 files changed

+43
-11
lines changed

11 files changed

+43
-11
lines changed

webtester-core/src/main/java/info/novatec/testit/webtester/browser/operations/PageSourceSaver.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
import java.io.File;
44
import java.io.IOException;
5+
import java.nio.charset.StandardCharsets;
56
import java.nio.file.Path;
67
import java.time.LocalDateTime;
78
import java.util.Optional;
@@ -191,7 +192,7 @@ private File doSavePageSource(File targetFolder, String fileNameWithoutSuffix) t
191192
String fileName = fileNameWithoutSuffix + ".html";
192193
File pageSource = new File(targetFolder, fileName);
193194

194-
FileUtils.write(pageSource, get());
195+
FileUtils.write(pageSource, get(), StandardCharsets.UTF_8);
195196

196197
log.debug("saved page source to file: {}", pageSource);
197198
fireEventIfEnabled(pageSource);

webtester-core/src/main/java/info/novatec/testit/webtester/conditions/Conditions.java

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ public class Conditions {
4444
* Creates a new {@link Is} condition.
4545
*
4646
* @param condition the nested condition
47+
* @param <T> the type of the condition
48+
* @return the created condition
4749
* @see Is
4850
* @since 2.0
4951
*/
@@ -55,6 +57,8 @@ public static <T> Is<T> is(Condition<T> condition) {
5557
* Creates a new {@link Has} condition.
5658
*
5759
* @param condition the nested condition
60+
* @param <T> the type of the condition
61+
* @return the created condition
5862
* @see Has
5963
* @since 2.0
6064
*/
@@ -66,6 +70,8 @@ public static <T> Has<T> has(Condition<T> condition) {
6670
* Creates a new {@link Not} condition.
6771
*
6872
* @param condition the nested condition
73+
* @param <T> the type of the condition
74+
* @return the created condition
6975
* @see Not
7076
* @since 2.0
7177
*/
@@ -77,6 +83,8 @@ public static <T> Not<T> not(Condition<T> condition) {
7783
* Creates a new {@link Either} condition.
7884
*
7985
* @param conditions the nested conditions
86+
* @param <T> the type of the condition
87+
* @return the created condition
8088
* @see Either
8189
* @since 2.1
8290
*/
@@ -88,6 +96,7 @@ public static <T> Either<T> either(Condition<T>... conditions) {
8896
* Creates a new {@link Attribute} condition.
8997
*
9098
* @param attributeName the name of the attribute to check
99+
* @return the created condition
91100
* @see Attribute
92101
* @since 2.0
93102
*/
@@ -100,6 +109,7 @@ public static Attribute attribute(String attributeName) {
100109
*
101110
* @param attributeName the name of the attribute to check
102111
* @param value the value to check
112+
* @return the created condition
103113
* @see AttributeWithValue
104114
* @since 2.0
105115
*/
@@ -110,6 +120,7 @@ public static AttributeWithValue attributeWithValue(String attributeName, Object
110120
/**
111121
* Creates a new {@link Disabled} condition.
112122
*
123+
* @return the created condition
113124
* @see Disabled
114125
* @since 2.0
115126
*/
@@ -120,6 +131,7 @@ public static Disabled disabled() {
120131
/**
121132
* Creates a new {@link Editable} condition.
122133
*
134+
* @return the created condition
123135
* @see Editable
124136
* @since 2.0
125137
*/
@@ -130,6 +142,7 @@ public static Editable editable() {
130142
/**
131143
* Creates a new {@link Enabled} condition.
132144
*
145+
* @return the created condition
133146
* @see Enabled
134147
* @since 2.0
135148
*/
@@ -140,6 +153,7 @@ public static Enabled enabled() {
140153
/**
141154
* Creates a new {@link Interactable} condition.
142155
*
156+
* @return the created condition
143157
* @see Interactable
144158
* @since 2.0
145159
*/
@@ -150,6 +164,7 @@ public static Interactable interactable() {
150164
/**
151165
* Creates a new {@link Invisible} condition.
152166
*
167+
* @return the created condition
153168
* @see Invisible
154169
* @since 2.0
155170
*/
@@ -160,6 +175,7 @@ public static Invisible invisible() {
160175
/**
161176
* Creates a new {@link Present} condition.
162177
*
178+
* @return the created condition
163179
* @see Present
164180
* @since 2.0
165181
*/
@@ -170,6 +186,7 @@ public static Present present() {
170186
/**
171187
* Creates a new {@link PresentAndVisible} condition.
172188
*
189+
* @return the created condition
173190
* @see PresentAndVisible
174191
* @since 2.0
175192
*/
@@ -180,6 +197,7 @@ public static PresentAndVisible presentAndVisible() {
180197
/**
181198
* Creates a new {@link ReadOnly} condition.
182199
*
200+
* @return the created condition
183201
* @see ReadOnly
184202
* @since 2.0
185203
*/
@@ -190,6 +208,7 @@ public static ReadOnly readOnly() {
190208
/**
191209
* Creates a new {@link Selected} condition.
192210
*
211+
* @return the created condition
193212
* @see Selected
194213
* @since 2.0
195214
*/
@@ -201,6 +220,7 @@ public static Selected selected() {
201220
* Creates a new {@link SelectedIndex} condition.
202221
*
203222
* @param index the expected selected index
223+
* @return the created condition
204224
* @see SelectedIndex
205225
* @since 2.0
206226
*/
@@ -212,6 +232,7 @@ public static SelectedIndex selectionWithIndex(Integer index) {
212232
* Creates a new {@link SelectedIndices} condition.
213233
*
214234
* @param indices the expected selected indices
235+
* @return the created condition
215236
* @see SelectedIndices
216237
* @since 2.0
217238
*/
@@ -223,6 +244,7 @@ public static SelectedIndices selectionWithIndices(Integer... indices) {
223244
* Creates a new {@link SelectedIndices} condition.
224245
*
225246
* @param indices the expected selected indices
247+
* @return the created condition
226248
* @see SelectedIndices
227249
* @since 2.0
228250
*/
@@ -234,6 +256,7 @@ public static SelectedIndices selectionWithIndices(Collection<Integer> indices)
234256
* Creates a new {@link SelectedText} condition.
235257
*
236258
* @param text the expected selected text
259+
* @return the created condition
237260
* @see SelectedText
238261
* @since 2.0
239262
*/
@@ -245,6 +268,7 @@ public static SelectedText selectionWithText(String text) {
245268
* Creates a new {@link SelectedTexts} condition.
246269
*
247270
* @param texts the expected selected texts
271+
* @return the created condition
248272
* @see SelectedTexts
249273
* @since 2.0
250274
*/
@@ -256,6 +280,7 @@ public static SelectedTexts selectionWithTexts(String... texts) {
256280
* Creates a new {@link SelectedTexts} condition.
257281
*
258282
* @param texts the expected selected texts
283+
* @return the created condition
259284
* @see SelectedTexts
260285
* @since 2.0
261286
*/
@@ -267,6 +292,7 @@ public static SelectedTexts selectionWithTexts(Collection<String> texts) {
267292
* Creates a new {@link SelectedValue} condition.
268293
*
269294
* @param value the expected selected value
295+
* @return the created condition
270296
* @see SelectedValue
271297
* @since 2.0
272298
*/
@@ -278,6 +304,7 @@ public static SelectedValue selectionWithValue(String value) {
278304
* Creates a new {@link SelectedValues} condition.
279305
*
280306
* @param values the expected selected values
307+
* @return the created condition
281308
* @see SelectedValues
282309
* @since 2.0
283310
*/
@@ -289,6 +316,7 @@ public static SelectedValues selectionWithValues(String... values) {
289316
* Creates a new {@link SelectedValues} condition.
290317
*
291318
* @param values the expected selected values
319+
* @return the created condition
292320
* @see SelectedValues
293321
* @since 2.0
294322
*/
@@ -299,6 +327,7 @@ public static SelectedValues selectionWithValues(Collection<String> values) {
299327
/**
300328
* Creates a new {@link Visible} condition.
301329
*
330+
* @return the created condition
302331
* @see Visible
303332
* @since 2.0
304333
*/
@@ -310,6 +339,7 @@ public static Visible visible() {
310339
* Creates a new {@link VisibleTextEquals} condition.
311340
*
312341
* @param text the expected visible text
342+
* @return the created condition
313343
* @see VisibleTextEquals
314344
* @since 2.0
315345
*/
@@ -321,6 +351,7 @@ public static VisibleTextEquals visibleText(String text) {
321351
* Creates a new {@link VisibleTextContains} condition.
322352
*
323353
* @param partialText the expected visible partial text
354+
* @return the created condition
324355
* @see VisibleTextContains
325356
* @since 2.0
326357
*/

webtester-core/src/test/java/info/novatec/testit/webtester/adhoc/TypeFinderTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import static java.util.Arrays.asList;
44
import static org.assertj.core.api.Assertions.assertThat;
5-
import static org.mockito.Matchers.any;
5+
import static org.mockito.ArgumentMatchers.any;
66
import static org.mockito.Mockito.doReturn;
77
import static org.mockito.Mockito.doThrow;
88
import static org.mockito.Mockito.mock;

webtester-core/src/test/java/info/novatec/testit/webtester/browser/operations/PageSourceSaverTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.browser.operations;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.any;
4+
import static org.mockito.ArgumentMatchers.any;
55
import static org.mockito.Mockito.doReturn;
66
import static org.mockito.Mockito.doThrow;
77
import static org.mockito.Mockito.never;

webtester-core/src/test/java/info/novatec/testit/webtester/browser/operations/ScreenshotTakerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.browser.operations;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.any;
4+
import static org.mockito.ArgumentMatchers.any;
55
import static org.mockito.Mockito.doReturn;
66
import static org.mockito.Mockito.doThrow;
77
import static org.mockito.Mockito.never;

webtester-core/src/test/java/info/novatec/testit/webtester/browser/operations/UrlOpenerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.browser.operations;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.any;
4+
import static org.mockito.ArgumentMatchers.any;
55
import static org.mockito.Mockito.doReturn;
66
import static org.mockito.Mockito.mock;
77
import static org.mockito.Mockito.verify;

webtester-core/src/test/java/info/novatec/testit/webtester/css/DefaultStyleChangerTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
package info.novatec.testit.webtester.css;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.any;
5-
import static org.mockito.Matchers.anyString;
4+
import static org.mockito.ArgumentMatchers.any;
5+
import static org.mockito.ArgumentMatchers.anyString;
66
import static org.mockito.Mockito.doReturn;
77
import static org.mockito.Mockito.doThrow;
88
import static org.mockito.Mockito.verify;

webtester-core/src/test/java/info/novatec/testit/webtester/markings/MarkerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.markings;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.same;
4+
import static org.mockito.ArgumentMatchers.same;
55
import static org.mockito.Mockito.doReturn;
66
import static org.mockito.Mockito.verify;
77
import static org.mockito.Mockito.verifyZeroInteractions;

webtester-core/src/test/java/info/novatec/testit/webtester/waiting/DefaultWaiterTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.waiting;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.anyLong;
4+
import static org.mockito.ArgumentMatchers.anyLong;
55
import static org.mockito.Mockito.doAnswer;
66
import static org.mockito.Mockito.doReturn;
77
import static org.mockito.Mockito.doThrow;

webtester-core/src/test/java/info/novatec/testit/webtester/waiting/WaitUntilTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package info.novatec.testit.webtester.waiting;
22

33
import static org.assertj.core.api.Assertions.assertThat;
4-
import static org.mockito.Matchers.same;
4+
import static org.mockito.ArgumentMatchers.same;
55
import static org.mockito.Mockito.verify;
66
import static org.mockito.Mockito.verifyZeroInteractions;
77

0 commit comments

Comments
 (0)