blob: 523b2261d00319c11b66d25dcc734e6881d266f5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
package org.openecomp.sdc.versioning.errors;
import org.junit.Assert;
import org.junit.Test;
import org.openecomp.sdc.common.errors.ErrorCategory;
import org.openecomp.sdc.common.errors.ErrorCode;
public class DeleteOnLockedEntityErrorBuilderTest {
@Test
public void test() {
DeleteOnLockedEntityErrorBuilder builder = new DeleteOnLockedEntityErrorBuilder("entityType",
"entityId", "lockingUser");
ErrorCode build = builder.build();
Assert.assertEquals(VersioningErrorCodes.DELETE_ON_LOCKED_ENTITY, build.id());
Assert.assertEquals(ErrorCategory.APPLICATION, build.category());
Assert.assertEquals(String.format(DeleteOnLockedEntityErrorBuilder.DELETE_ON_LOCKED_ENTITY_MSG,
"entityType", "entityId", "lockingUser"), build.message());
}
}
|