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

GatewayTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 1
c 1
b 0
f 1
dl 0
loc 22
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A testGetSecureUrl() 0 20 1
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