1 | <?php |
||
20 | class FeatureContext implements Context |
||
|
|||
21 | { |
||
22 | /** |
||
23 | * Initializes context. |
||
24 | */ |
||
25 | public function __construct() |
||
29 | |||
30 | /** |
||
31 | * @Given /(\S+) (\S+) price is ([0-9.]+) (\w+) per ([0-9.]+) (\w+)/ |
||
32 | */ |
||
33 | public function price($target, $type, $sum, $currency, $amount, $unit) |
||
41 | |||
42 | /** |
||
43 | * @Given /action is (\S+) (\w+) ([0-9.]+) (\S+)/ |
||
44 | */ |
||
45 | public function action($target, $type, $amount, $unit) |
||
53 | |||
54 | /** |
||
55 | * @Given /formula (.+)/ |
||
56 | */ |
||
57 | public function formula($formula) |
||
61 | |||
62 | /** |
||
63 | * @When /date is ([0-9.-]+)/ |
||
64 | */ |
||
65 | public function dateIs($date) |
||
69 | |||
70 | /** |
||
71 | * @Then /first charge is (\S+)? ?([0-9.]+)? ?([A-Z]{3})?/ |
||
72 | */ |
||
73 | public function firstCharge($type = null, $sum = null, $currency = null) |
||
77 | |||
78 | /** |
||
79 | * @Then /second charge is (\S+)? ?([0-9.]+)? ?([A-Z]{3})?/ |
||
80 | */ |
||
81 | public function secondCharge($type = null, $sum = null, $currency = null) |
||
85 | |||
86 | /** |
||
87 | * @Then /third charge is (\S+)? ?([0-9.]+)? ?([A-Z]{3})?/ |
||
88 | */ |
||
89 | public function thirdCharge($type = null, $sum = null, $currency = null) |
||
93 | |||
94 | public function charge($no, $type, $sum = null, $currency = null) |
||
102 | } |
||
103 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.