mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-08-14 12:26:24 +00:00
docs: update throttling
This commit is contained in:
@@ -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