@@ -4,11 +4,6 @@ title: Introduction - Codeception Docs
44---
55
66
7- ---
8- layout: doc
9- title: 01-Introduction - Codeception - Documentation
10- ---
11-
127# Introduction
138
149The idea behind testing is not new. You can't sleep well if you are not confident
@@ -55,18 +50,15 @@ With acceptance tests, you can be confident that users, following all the define
5550
5651#### Sample acceptance test
5752
58- {% highlight php %}
59-
60- <? php
53+ ``` php
6154$I->amOnPage('/');
6255$I->click('Sign Up');
6356$I->submitForm('#signup', [
6457 'username' => 'MilesDavis',
6558 'email' => 'miles@davis.com'
6659]);
6760$I->see('Thank you for Signing Up!');
68-
69- {% endhighlight %}
61+ ```
7062
7163### Functional Tests
7264
@@ -79,17 +71,14 @@ For functional tests, your application needs to be structured in order to run in
7971
8072#### Sample functional test
8173
82- {% highlight php %}
83-
84- <? php
74+ ``` php
8575$I->amOnPage('/');
8676$I->click('Sign Up');
8777$I->submitForm('#signup', ['username' => 'MilesDavis', 'email' => 'miles@davis.com']);
8878$I->see('Thank you for Signing Up!');
8979$I->seeEmailSent('miles@davis.com', 'Thank you for registration');
9080$I->seeInDatabase('users', ['email' => 'miles@davis.com']);
91-
92- {% endhighlight %}
81+ ```
9382
9483> This looks very similar to acceptance tests. The behavior is the same, however, the test is executed inside PHP without launching a browser.
9584
@@ -109,9 +98,7 @@ The better you understand the testing scenario, the faster you can update it for
10998
11099#### Sample integration test
111100
112- {% highlight php %}
113-
114- <? php
101+ ``` php
115102public function testSavingUser()
116103{
117104 $user = new User();
@@ -124,8 +111,7 @@ public function testSavingUser()
124111 'surname' => 'Davis'
125112 ]);
126113}
127-
128- {% endhighlight %}
114+ ```
129115
130116## Conclusion
131117
0 commit comments