Exemplo n.º 1
0
func (executor *specExecutor) executeConcept(protoConcept *gauge_messages.ProtoConcept) bool {
	executor.logger.Info("Executing Concept: %s", formatter.FormatConcept(protoConcept))
	for _, step := range protoConcept.Steps {
		failure := executor.executeItem(step)
		executor.setExecutionResultForConcept(protoConcept)
		if failure {
			return true
		}
	}
	return protoConcept.GetConceptExecutionResult().GetExecutionResult().GetFailed()
}
Exemplo n.º 2
0
func (executor *specExecutor) executeConcept(protoConcept *gauge_messages.ProtoConcept) bool {
	executor.consoleReporter.ConceptStart(formatter.FormatConcept(protoConcept))
	for _, step := range protoConcept.Steps {
		failure := executor.executeItem(step)
		executor.setExecutionResultForConcept(protoConcept)
		if failure {
			return true
		}
	}
	conceptFailed := protoConcept.GetConceptExecutionResult().GetExecutionResult().GetFailed()
	executor.consoleReporter.ConceptEnd(conceptFailed)
	return conceptFailed
}
Exemplo n.º 3
0
func (e *scenarioExecutor) executeConcept(protoConcept *gauge_messages.ProtoConcept) *gauge_messages.ProtoStepExecutionResult {
	e.consoleReporter.ConceptStart(formatter.FormatConcept(protoConcept))
	for _, step := range protoConcept.Steps {
		res := e.executeItem(step)
		e.setExecutionResultForConcept(protoConcept)
		if res.GetExecutionResult().GetFailed() {
			return protoConcept.GetConceptExecutionResult()
		}
	}
	conceptFailed := protoConcept.GetConceptExecutionResult().GetExecutionResult().GetFailed()
	e.consoleReporter.ConceptEnd(conceptFailed)
	return protoConcept.GetConceptExecutionResult()
}
Exemplo n.º 4
0
func (writer *simpleLogger) ConceptStarting(protoConcept *gauge_messages.ProtoConcept) {
	writer.Text(formatter.FormatConcept(protoConcept))
	writer.indentation += 4
}
Exemplo n.º 5
0
func (writer *coloredLogger) ConceptStarting(protoConcept *gauge_messages.ProtoConcept) {
	conceptText := indent(formatter.FormatConcept(protoConcept), writer.indentation)
	terminal.Stdout.Colorf("@b%s", conceptText)
	writer.indentation += 4
}