52599ecca474731ec4f925a13d409f682ebb1dd2
[sdc.git] /
1 package org.openecomp.sdc.versioning.errors;
2
3
4 import org.junit.Assert;
5 import org.junit.Test;
6 import org.openecomp.sdc.common.errors.ErrorCategory;
7 import org.openecomp.sdc.common.errors.ErrorCode;
8
9 public class UndoCheckoutOnUnlockedEntityErrorBuilderTest {
10     @Test
11     public void test() {
12         UndoCheckoutOnUnlockedEntityErrorBuilder builder = new UndoCheckoutOnUnlockedEntityErrorBuilder("entityType",
13                 "entityId");
14         ErrorCode build = builder.build();
15         Assert.assertEquals(VersioningErrorCodes.UNDO_CHECKOUT_ON_UNLOCKED_ENTITY, build.id());
16         Assert.assertEquals(ErrorCategory.APPLICATION, build.category());
17         Assert.assertEquals(String.format(UndoCheckoutOnUnlockedEntityErrorBuilder.UNDO_CHECKOUT_ON_UNLOCKED_ENTITY_MSG,
18                 "entityType", "entityId"), build.message());
19     }
20 }