test_class.file: step-plans/step-plans-parser/src/test/java/step/repositories/parser/CustomExpectedStepParserTest.java
test_class.identifier: CustomExpectedStepParserTest
test_class.superclass: extends AbstractStepParserTest
test_case.body: @Test
  	public void test() throws ParsingException {
  		List<AbstractStep> steps = new ArrayList<>();
  		steps.add(step("Key1 = \"Value1\" \n \u00A0Key2 = \"Value 2\""));
  		steps.add(step("Key1 ~ \".*\""));
  		
  		AbstractArtefact root = parse(steps);
  		Assert.assertEquals(3,getChildren(root).size());
  		
  		step.artefacts.Assert check1 = (step.artefacts.Assert ) getChildren(root).get(0);
  		Assert.assertEquals("\"Value1\"",check1.getExpected().getExpression());
  		Assert.assertEquals(AssertOperator.EQUALS,check1.getOperator());
  		Assert.assertEquals("Key1=\"Value1\"", check1.getCustomAttribute("check"));
  		
  		step.artefacts.Assert check2 = (step.artefacts.Assert ) getChildren(root).get(1);
  		Assert.assertEquals("\"Value 2\"",check2.getExpected().getExpression());
  		Assert.assertEquals("Key2=\"Value 2\"", check2.getCustomAttribute("check"));
  
  		
  		step.artefacts.Assert check3 = (step.artefacts.Assert ) getChildren(root).get(2);
  		Assert.assertEquals("\".*\"",check3.getExpected().getExpression());
  		Assert.assertEquals(AssertOperator.MATCHES,check3.getOperator());
  	}
test_case.class_method_signature: CustomExpectedStepParserTest.test()
test_case.full_signature: @Test public void test()
test_case.identifier: test
test_case.invocations: add step add step parse assertEquals size getChildren get getChildren assertEquals getExpression getExpected assertEquals getOperator assertEquals getCustomAttribute get getChildren assertEquals getExpression getExpected assertEquals getCustomAttribute get getChildren assertEquals getExpression getExpected assertEquals getOperator
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void test()
focal_class.file: step-plans/step-plans-parser/src/main/java/step/repositories/parser/CustomExpectedStepParser.java
focal_class.identifier: CustomExpectedStepParser
focal_class.interfaces: implements StepParser<ExpectedStep>
focal_class.class_method_signature: CustomExpectedStepParser.getParserScoreForStep(AbstractStep step)
focal_class.full_signature: @Override public int getParserScoreForStep(AbstractStep step)
focal_class.identifier: getParserScoreForStep
focal_class.modifiers: @Override public
focal_class.parameters: (AbstractStep step)
focal_class.return: int
focal_class.signature: int getParserScoreForStep(AbstractStep step)
focal_class.class_method_signature: CustomExpectedStepParser.parseStep(ParsingContext parsingContext, ExpectedStep step)
focal_class.full_signature: @Override public void parseStep(ParsingContext parsingContext, ExpectedStep step)
focal_class.identifier: parseStep
focal_class.modifiers: @Override public
focal_class.parameters: (ParsingContext parsingContext, ExpectedStep step)
focal_class.return: void
focal_class.signature: void parseStep(ParsingContext parsingContext, ExpectedStep step)
focal_class.class_method_signature: CustomExpectedStepParser.parse(String expression)
focal_class.full_signature: private ParseContext parse(String expression)
focal_class.identifier: parse
focal_class.modifiers: private
focal_class.parameters: (String expression)
focal_class.return: ParseContext
focal_class.signature: ParseContext parse(String expression)
focal_method.body: private ParseContext parse(String expression) {
  		ExpectedStepLexer lexer = new ExpectedStepLexer(new ANTLRInputStream(expression));
  		ExpectedStepParser parser = new ExpectedStepParser(new CommonTokenStream(lexer));
  		parser.addErrorListener(new BaseErrorListener() {
  	        @Override
  	        public void syntaxError(Recognizer<?, ?> recognizer, Object offendingSymbol, int line, int charPositionInLine, String msg, RecognitionException e) {
  	            throw new IllegalStateException("failed to parse at line " + line + " due to " + msg, e);
  	        }
  	    });
  		return parser.parse();
  		
  	}
focal_method.class_method_signature: CustomExpectedStepParser.parse(String expression)
focal_method.full_signature: private ParseContext parse(String expression)
focal_method.identifier: parse
focal_method.invocations: addErrorListener parse
focal_method.modifiers: private
focal_method.parameters: (String expression)
focal_method.return: ParseContext
focal_method.signature: ParseContext parse(String expression)