1 | <?php |
||
37 | class TextEditorContext extends RawMinkContext implements Context { |
||
38 | |||
39 | use BasicStructure; |
||
40 | |||
41 | private $adminPassword; |
||
42 | private $textEditorPage; |
||
43 | private $featureContext; |
||
44 | private $filesContext; |
||
45 | |||
46 | /** |
||
47 | * TextEditorContext constructor. |
||
48 | * |
||
49 | * @param TextEditorPage $textEditorPage |
||
50 | */ |
||
51 | public function __construct(TextEditorPage $textEditorPage) { |
||
54 | |||
55 | /** |
||
56 | * @When /^I create a text file with the name ((?:'[^']*')|(?:"[^"]*"))( without changing the default file extension|)$/ |
||
57 | * |
||
58 | * @param string $name |
||
59 | * @param string $useDefaultFileExtension |
||
60 | * @return void |
||
61 | */ |
||
62 | public function createATextFileWithTheName( |
||
76 | |||
77 | |||
78 | /** |
||
79 | * @Then near the new text file box a tooltip with the text :toolTipText should be displayed |
||
80 | * @param string $toolTipText |
||
81 | * @return void |
||
82 | */ |
||
83 | public function nearTheNewTextFileBoxATooltipShouldBeDisplayed($toolTipText) { |
||
89 | |||
90 | /** |
||
91 | * @When I input :text in the text area |
||
92 | * @param string $text |
||
93 | * @return void |
||
94 | */ |
||
95 | public function iInputTextInTheTextArea($text) { |
||
101 | |||
102 | /** |
||
103 | * @When I input the following text in the text area: |
||
104 | * @param PyStringNode $multiLineText |
||
105 | * @return void |
||
106 | */ |
||
107 | public function iInputTheFollowingInTheTextArea(PyStringNode $multiLineText) { |
||
113 | |||
114 | /** |
||
115 | * @Then there is/are :number line(s) of text |
||
116 | * @param int $number |
||
117 | * @return void |
||
118 | */ |
||
119 | public function thereAreLinesOfText($number) { |
||
125 | |||
126 | /** |
||
127 | * @Then line :number of the text is :text |
||
128 | * @param int $number |
||
129 | * @param string $text |
||
130 | * @return void |
||
131 | */ |
||
132 | public function lineOfTheTextIs($number, $text) { |
||
140 | /** |
||
141 | * @When I close the text editor |
||
142 | * @return void |
||
143 | */ |
||
144 | public function iCloseTheTextEditor() { |
||
147 | |||
148 | /** |
||
149 | * general before scenario for all text editor tests. |
||
150 | * This will run before EVERY scenario. |
||
151 | * It will set the properties for this object. |
||
152 | * |
||
153 | * @param BeforeScenarioScope $scope |
||
154 | * @return void |
||
155 | * @BeforeScenario |
||
156 | */ |
||
157 | public function before(BeforeScenarioScope $scope) { |
||
172 | } |
||
173 |