AG
Size: a a a
AG
AG
DK
Д
Д
Д
DC
V
КХ
КХ
А
А
XSSFWorkbook workbook = new XSSFWorkbook(new FileInputStream(path));
XSSFSheet sheet = workbook.getSheet(sheetName);
workbook.write(new FileOutputStream(new File(outputPath)));
А
.OpenXML4JRuntimeException: Rule M2.4 exception : this error should NEVER happen, if so please send a mail to the developers team, thanks !
ch
А
А
КХ
КХ
public class UserConditions {
public static Condition<User> young = new Condition<>(u -> u.getAge() <=30, "young (age <= 30)");
public static Condition<User> usernameIsJohn = new Condition<>(u -> u.getUsername().equalsIgnoreCase("John"), "username == John");
}
...
@Test
void savedUserUsernameIsNotJhonAndYoung() {
User user = new User("John", "zaphod@mail.com");
user.setAge(10);
assertThat(user).as("check %s's age and username", user.getUsername())
.is(allOf(young, not(usernameIsJohn)));
java.lang.AssertionError: [check John's age and username]
Expecting:
<User(id=null, username=John, email=zaphod@mail.com, registrationDate=null, age=10)>
to be <all of:[
young (age <= 30),
Not
]>
at ...
assertThat(user).as("check %s's age and username", user.getUsername())
.is(allOf(young, usernameIsJohn));
java.lang.AssertionError: [check JohnZ's age and username]
Expecting:
<User(id=null, username=JohnZ, email=zaphod@mail.com, registrationDate=null, age=10)>
to be <all of:[
young (age <= 30),
username == John
]>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<version>3.18.1</version>
<scope>test</scope>
</dependency>
A
GV