mirror of
https://github.com/square/okhttp.git
synced 2026-01-17 08:42:25 +03:00
Merge pull request #4474 from seratch/typo-in-tests
Fix typo/misspellings in tests
This commit is contained in:
@@ -129,35 +129,35 @@ public final class DiskLruCacheTest {
|
||||
try {
|
||||
key = "has_space ";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was invalid.");
|
||||
fail("Expecting an IllegalArgumentException as the key was invalid.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
try {
|
||||
key = "has_CR\r";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was invalid.");
|
||||
fail("Expecting an IllegalArgumentException as the key was invalid.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
try {
|
||||
key = "has_LF\n";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was invalid.");
|
||||
fail("Expecting an IllegalArgumentException as the key was invalid.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
try {
|
||||
key = "has_invalid/";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was invalid.");
|
||||
fail("Expecting an IllegalArgumentException as the key was invalid.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
try {
|
||||
key = "has_invalid\u2603";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was invalid.");
|
||||
fail("Expecting an IllegalArgumentException as the key was invalid.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
@@ -165,7 +165,7 @@ public final class DiskLruCacheTest {
|
||||
key = "this_is_way_too_long_this_is_way_too_long_this_is_way_too_long_"
|
||||
+ "this_is_way_too_long_this_is_way_too_long_this_is_way_too_long";
|
||||
cache.edit(key);
|
||||
fail("Exepcting an IllegalArgumentException as the key was too long.");
|
||||
fail("Expecting an IllegalArgumentException as the key was too long.");
|
||||
} catch (IllegalArgumentException iae) {
|
||||
assertEquals("keys must match regex [a-z0-9_-]{1,120}: \"" + key + "\"", iae.getMessage());
|
||||
}
|
||||
|
||||
@@ -352,7 +352,7 @@ public final class HttpOverHttp2Test {
|
||||
waitForDataFrames(Http2Connection.OKHTTP_CLIENT_WINDOW_SIZE);
|
||||
|
||||
// Cancel the call and close the response body. This should discard the buffered data and update
|
||||
// the connnection flow-control window.
|
||||
// the connection flow-control window.
|
||||
call1.cancel();
|
||||
response1.close();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user