Passed
Push — master ( f242a8...af9927 )
by Aimeos
04:38
created

CheckoutControllerTest::setUp()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
class CheckoutControllerTest extends AimeosTestAbstract
4
{
5
	public function testConfirmAction()
6
	{
7
		View::addLocation(dirname(__DIR__).'/fixtures/views');
8
9
		$response = $this->action('GET', '\Aimeos\Shop\Controller\CheckoutController@confirmAction', ['site' => 'unittest']);
10
11
		$this->assertResponseOk();
12
		$this->assertContains('<section class="aimeos checkout-confirm"', $response->getContent());
13
	}
14
15
16
	public function testIndexAction()
17
	{
18
		View::addLocation(dirname(__DIR__).'/fixtures/views');
19
20
		$response = $this->action('GET', '\Aimeos\Shop\Controller\CheckoutController@indexAction', ['site' => 'unittest']);
21
22
		$this->assertResponseOk();
23
		$this->assertContains('<section class="checkout-standard-address"', $response->getContent());
24
	}
25
26
27
	public function testUpdateAction()
28
	{
29
		View::addLocation(dirname(__DIR__).'/fixtures/views');
30
31
		$response = $this->action('GET', '\Aimeos\Shop\Controller\CheckoutController@updateAction', ['site' => 'unittest'], ['code' => 'paypalexpress']);
32
33
		$this->assertResponseOk();
34
		$this->assertEquals('', $response->getContent());
35
	}
36
}