diff options
| author | Ben Culkin <scorpress@gmail.com> | 2021-03-13 10:13:12 -0500 |
|---|---|---|
| committer | Ben Culkin <scorpress@gmail.com> | 2021-03-13 10:13:12 -0500 |
| commit | 58e0022923d573782f5db1f22a1713a98712e37b (patch) | |
| tree | b6f1543d41c22e4d79c6f62ab7246474f7d4bf8e /base/src/main/java/bjc/utils/funcutils/TestUtils.java | |
| parent | 89ecc3004f9f513d249d9df9b2e48e08fd56f315 (diff) | |
Update documentation
Diffstat (limited to 'base/src/main/java/bjc/utils/funcutils/TestUtils.java')
| -rw-r--r-- | base/src/main/java/bjc/utils/funcutils/TestUtils.java | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/base/src/main/java/bjc/utils/funcutils/TestUtils.java b/base/src/main/java/bjc/utils/funcutils/TestUtils.java index c7aeec1..bf38cbe 100644 --- a/base/src/main/java/bjc/utils/funcutils/TestUtils.java +++ b/base/src/main/java/bjc/utils/funcutils/TestUtils.java @@ -15,10 +15,9 @@ public class TestUtils { /** * Assert an iterator provides a particular sequence of values. * - * @param src - * The iterator to pull values from. - * @param vals - * The values to expect from the iterator. + * @param <T> The type of the values. + * @param src The iterator to pull values from. + * @param vals The values to expect from the iterator. */ @SafeVarargs public static <T> void assertIteratorEquals(Iterator<T> src, T... vals) { @@ -28,12 +27,10 @@ public class TestUtils { /** * Assert an iterator provides a particular sequence of values. * - * @param src - * The iterator to pull values from. - * @param hasMore - * The expected value of hasNext for the iterator. - * @param vals - * The values to expect from the iterator. + * @param <T> The type of the values. + * @param src The iterator to pull values from. + * @param hasMore The expected value of hasNext for the iterator. + * @param vals The values to expect from the iterator. */ @SafeVarargs public static <T> void assertIteratorEquals(boolean hasMore, Iterator<T> src, @@ -44,6 +41,8 @@ public class TestUtils { * Even though it's awkward, the boolean has to come first. Otherwise, there are * cases where the compiler will get confused as to what the right value for T * is, and be unable to pick an overload. + * + * This is a case where named parameter would be rather useful. */ assertIteratorEquals(src, vals); @@ -53,11 +52,9 @@ public class TestUtils { /** * Assert that a list has a given set of contents. * - * @param src - * The list of actual elements. - * - * @param exps - * The list of expected elements. + * @param <T> The type of the values. + * @param src The list of actual elements. + * @param exps The list of expected elements. */ @SafeVarargs public static <T> void assertListEquals(List<T> src, T... exps) { |
