Open Monograph Press
3.3.0
|
6 use Omnipay\Tests\TestCase;
13 $this->assertEquals(
'testCase', $result);
19 $this->assertEquals(
'testCase', $result);
25 $this->assertEquals(
'testCase', $result);
31 $this->assertTrue($result);
37 $this->assertFalse($result);
43 $this->assertTrue($result);
60 $target = m::mock(
'\Omnipay\Common\CreditCard');
61 $target->shouldReceive(
'setName')->once()->with(
'adrian');
62 $target->shouldReceive(
'setNumber')->once()->with(
'1234');
69 $target = m::mock(
'\Omnipay\Common\CreditCard');
70 $target->shouldReceive(
'setName')->once()->with(
'adrian');
78 $this->assertSame(
'Stripe', $shortName);
84 $this->assertSame(
'Stripe', $shortName);
90 $this->assertSame(
'PayPal_Express', $shortName);
96 $this->assertSame(
'PayPal_Express', $shortName);
102 $this->assertSame(
'\\Custom\\Gateway', $shortName);
111 $this->assertEquals(
'\\Custom\\Gateway', $class);
120 $this->assertEquals(
'\\Custom_Gateway', $class);
126 $this->assertEquals(
'\\Omnipay\\Stripe\\Gateway', $class);
132 $this->assertEquals(
'\\Omnipay\\PayPal\\ExpressGateway', $class);
141 $this->assertEquals(
'\\Omnipay\\PayPal\\ExpressGateway', $class);
150 $this->assertSame(1.99, $shortName);
156 $this->assertSame(199.0, $shortName);
162 $this->assertSame(1.99, $shortName);
168 $this->assertSame(9.999, $shortName);
174 $this->assertSame(1.0, $shortName);
180 $this->assertSame(199.0, $shortName);
186 $this->assertSame(-199.0, $shortName);
testInitializeIgnoresNull()
testToFloatFromStringRedunantZeroes()
static validateLuhn($number)
testInitializeIgnoresString()
testGetGatewayClassNameSimple()
testToFloatFromStringWrongDecimalPoints()
testGetGatewayClassNameUnderscoreNamespace()
testToFloatFromStringTwoDecimalPoints()
static initialize($target, $parameters)
testToFloatFromStringDecimal()
testGetGatewayShortNameCustomGateway()
testValidateLuhnInvalid()
testToFloatFromStringIntNegative()
testGetGatewayClassNamePartialNamespace()
testGetGatewayShortNameUnderscoreLeadingSlash()
testToFloatFromStringEmptyIntegerPart()
testGetGatewayShortNameSimple()
testGetGatewayClassNameExistingNamespace()
testToFloatFromStringInt()
testGetGatewayShortNameSimpleLeadingSlash()
static getGatewayShortName($className)
testGetGatewayShortNameUnderscore()
testGetGatewayClassNameExistingNamespaceUnderscore()
testCamelCaseAlreadyCorrect()
testInitializeIgnoresInvalidParameters()
testCamelCaseWithUppercaseValue()
testToFloatFromStringEmptyDecimal()
static getGatewayClassName($shortName)
testInitializeCallsSetters()