b2287611fc61d5f8047cf4d2f5c32c29a82af8f6
[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 EditOnUnlockedEntityErrorBuilderTest {
10     @Test
11     public void test() {
12         EditOnUnlockedEntityErrorBuilder builder = new EditOnUnlockedEntityErrorBuilder("entityType",
13                 "entityId");
14
15         ErrorCode build = builder.build();
16         Assert.assertEquals(VersioningErrorCodes.EDIT_ON_UNLOCKED_ENTITY, build.id());
17         Assert.assertEquals(ErrorCategory.APPLICATION, build.category());
18         Assert.assertEquals(String.format(EditOnUnlockedEntityErrorBuilder.EDIT_ON_UNLOCKED_ENTITY_MSG,
19                 "entityType", "entityId"), build.message());
20     }
21 }