mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-10-12 16:15:23 +00:00
docs: update throttling
This commit is contained in:
1 parent
16fbd26a42
commit
628ec1548c
3 files changed
+83
-63
No files matched your search
@@ -30,11 +30,10 @@ import lombok.Getter;
|
||||
/**
|
||||
* BarCustomer is a tenant with a name and a number of allowed calls per second.
|
||||
*/
|
||||
@Getter
|
||||
public class BarCustomer {
|
||||
|
||||
@Getter
|
||||
private final String name;
|
||||
@Getter
|
||||
private final int allowedCallsPerSecond;
|
||||
|
||||
/**
|
||||
|
||||
@@ -36,8 +36,6 @@ class BarCustomerTest {
|
||||
|
||||
@Test
|
||||
void constructorTest() {
|
||||
assertThrows(InvalidParameterException.class, () -> {
|
||||
new BarCustomer("sirBrave", -1, new CallsCount());
|
||||
});
|
||||
assertThrows(InvalidParameterException.class, () -> new BarCustomer("sirBrave", -1, new CallsCount()));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user