Completed
Push — master ( 05a429...b45f19 )
by Gabriel
10:23 queued 05:22
created

GatewayTest::testGetSecureUrl()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 20
Code Lines 12

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 20
rs 9.4285
cc 1
eloc 12
nc 1
nop 0
1
<?php
2
3
namespace ByTIC\Omnipay\Twispay\Tests;
4
5
use ByTIC\Omnipay\Twispay\Gateway;
6
7
/**
8
 * Class HelperTest
9
 * @package ByTIC\Omnipay\Twispay\Tests
10
 */
11
class GatewayTest extends AbstractTest
12
{
13
    public function testGetSecureUrl()
14
    {
15
        $gateway = new Gateway();
16
17
        // INITIAL TEST MODE IS TRUE
18
        self::assertEquals(
19
            'https://secure-stage.twispay.com',
20
            $gateway->getSecureUrl()
21
        );
22
23
        $gateway->setTestMode(true);
24
        self::assertEquals(
25
            'https://secure-stage.twispay.com',
26
            $gateway->getSecureUrl()
27
        );
28
29
        $gateway->setTestMode(false);
30
        self::assertEquals(
31
            'https://secure.twispay.com',
32
            $gateway->getSecureUrl()
33
        );
34
    }
35
}
36