1 | <?php |
||
34 | class TextEditorContext extends RawMinkContext implements Context { |
||
35 | private $textEditorPage; |
||
36 | private $featureContext; |
||
37 | private $filesContext; |
||
38 | |||
39 | /** |
||
40 | * TextEditorContext constructor. |
||
41 | * |
||
42 | * @param TextEditorPage $textEditorPage |
||
43 | */ |
||
44 | public function __construct(TextEditorPage $textEditorPage) { |
||
47 | |||
48 | /** |
||
49 | * @When /^I create a text file with the name ((?:'[^']*')|(?:"[^"]*"))( without changing the default file extension|)$/ |
||
50 | * |
||
51 | * @param string $name |
||
52 | * @param string $useDefaultFileExtension |
||
53 | * @return void |
||
54 | */ |
||
55 | public function createATextFileWithTheName( |
||
69 | |||
70 | /** |
||
71 | * @When I input :text in the text area |
||
72 | * @param string $text |
||
73 | * @return void |
||
74 | */ |
||
75 | public function iInputTextInTheTextArea($text) { |
||
78 | |||
79 | /** |
||
80 | * @When I input the following text in the text area: |
||
81 | * @param PyStringNode $multiLineText |
||
82 | * @return void |
||
83 | */ |
||
84 | public function iInputTheFollowingInTheTextArea(PyStringNode $multiLineText) { |
||
87 | |||
88 | /** |
||
89 | * @Then there is/are :number line(s) of text |
||
90 | * @param int $number |
||
91 | * @return void |
||
92 | */ |
||
93 | public function thereAreLinesOfText($number) { |
||
99 | |||
100 | /** |
||
101 | * @Then line :number of the text is :text |
||
102 | * @param int $number |
||
103 | * @param string $text |
||
104 | * @return void |
||
105 | */ |
||
106 | public function lineOfTheTextIs($number, $text) { |
||
114 | /** |
||
115 | * @When I close the text editor |
||
116 | * @return void |
||
117 | */ |
||
118 | public function iCloseTheTextEditor() { |
||
129 | /** |
||
130 | * general before scenario for all text editor tests. |
||
131 | * This will run before EVERY scenario. |
||
132 | * It will set the properties for this object. |
||
133 | * |
||
134 | * @param BeforeScenarioScope $scope |
||
135 | * @return void |
||
136 | * @BeforeScenario |
||
137 | */ |
||
138 | public function before(BeforeScenarioScope $scope) { |
||
149 | } |
||
150 |