mercredi 31 janvier 2018

Dynamic parameter cannot be resolved in Gauge

i try to use the file special parameter in a Gauge specification.

Export a customer
----------------------------------------
* Find customer "Hans"
* Export customer to <file:/customer.xml>

The java implementation for this looks like this

@Step("Export tenant to <file>")
public void test(String file) {
   System.out.println("file " + file);
}

I assume the parameter typ is String (can it also be File ?)

But nevertheless, running this, returns

[ParseError] C:\Users\user\IdeaProjects\qmsgauge\specs\tenantManagement.spec:40 
 Dynamic parameter <file:/customer.xml> could not be resolved => 'Export customer to <file:/customers.xml>'
Successfully generated html-report to => C:\Users\user\IdeaProjects\qmsgauge\reports\html-report\index.html

How do I define the file parameter in the spec and how do need to write the java implementation for this ?

Thanks

Aucun commentaire:

Enregistrer un commentaire