ESMSMissingParamTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 25
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testSendSMS() 0 6 1
A testSendVoiceCall() 0 7 1
1
<?php
2
/**
3
 * @link https://github.com/yiiviet/yii2-esms
4
 * @copyright Copyright (c) 2017 Yii Viet
5
 * @license [New BSD License](http://www.opensource.org/licenses/bsd-license.php)
6
 */
7
8
9
namespace yiiviet\tests\unit\esms;
10
11
/**
12
 * Lớp ESMSMissingParamTest
13
 *
14
 * @author Vuong Minh <[email protected]>
15
 * @since 1.0
16
 */
17
class ESMSMissingParamTest extends TestCase
18
{
19
20
    /**
21
     * @expectedException \yii\base\InvalidConfigException
22
     */
23
    public function testSendSMS()
24
    {
25
        $this->eSMS->sendSMS([
26
            'Content' => 'Hweeeeeeeeeeee'
27
        ]);
28
    }
29
30
    /**
31
     * @expectedException \yii\base\InvalidConfigException
32
     */
33
    public function testSendVoiceCall()
34
    {
35
        $this->eSMS->sendVoice([
36
            'ApiCode' => '96cd1977-dc4e-48d5-8ef9-cd4837840250',
37
            'PassCode' => '96cd1977-dc4e-48d5-8ef9-cd4837840250'
38
        ]);
39
    }
40
41
}
42