/*
 * Copyright 2021 B2i Healthcare Pte Ltd, http://b2i.sg
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.b2international.snowowl.snomed.core.rest;

import static com.b2international.snowowl.snomed.core.rest.SnomedRestFixtures.createNewConcept;
import static com.b2international.snowowl.test.commons.codesystem.CodeSystemRestRequests.createCodeSystem;

import java.util.List;

import org.junit.Test;

import com.b2international.snowowl.snomed.core.domain.SnomedConcept;

/**
 * @since 7.17.0
 */
public class SnomedExpressionLabelTest extends SnomedExpressionLabelRequests{
	@Test
	public void getEcl() throws Exception {
		String conceptId = createNewConcept(branchPath);

		String shortName = "SNOMEDCT-Test";
		createCodeSystem(branchPath, shortName).statusCode(201);
		
		List<String> expressionLabels = getExpressionLabels(branchPath.getPath(), List.of(conceptId));
		
		SnomedConcept concept = getConcept(conceptId, "term()");
		
		expressionLabels.stream().findFirst().ifPresent(label -> label.equals(conceptId + " |" + concept.getFsn() + "|" ));

	}

}

@@ -873,16 +873,108 @@
 eSystem;
+%0Aimport static org.hamcrest.CoreMatchers.equalTo;%0Aimport static org.junit.Assert.assertThat;
 %0A%0Aimport
@@ -1552,16 +1552,27 @@
 );%0A%09%09%0A%09%09
+assertThat(
 expressi
@@ -1605,39 +1605,22 @@
 t().
-ifPresent(label -%3E label.
+get(), 
 equal
-s
+To
 (con
@@ -1661,14 +1661,12 @@
  %22%7C%22
- 
 ));%0A
-%0A
 %09%7D%0A%0A

add assertion