Completed
Push — master ( 3528be...829c65 )
by Laurynas
03:21
created

QuestionsTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A testGetQuestions() 0 11 1
1
<?php
2
3
use Qualia\Configuration\Questions;
4
5
class QuestionsTest extends TestCase
0 ignored issues
show
Coding Style Compatibility introduced by
PSR1 recommends that each class must be in a namespace of at least one level to avoid collisions.

You can fix this by adding a namespace to your class:

namespace YourVendor;

class YourClass { }

When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.

Loading history...
6
{
7
8
    public function testGetQuestions()
9
    {
10
        $questions = Questions::get($this->client);
11
12
        self::assertArrayHasKey('surveys', $questions);
13
        self::assertCount(2, $questions['surveys']);
14
        self::assertArrayHasKey('structure', $questions);
15
        self::assertArrayHasKey('q_1J75WdyBwVpwlJUM', $questions['structure'], "Date Question disappeared!");
16
        self::assertArrayHasKey('q_tVabQ3cUlwZTgQ10', $questions['structure'], "Checkbox Question disappeared!");
17
        self::assertArrayHasKey('q_KCyzOs7VqevWbEO0', $questions['structure'], "Name Question disappeared!");
18
        self::assertArrayHasKey('q_3RYJ4MpggyMFuU50', $questions['structure'], "Email Question disappeared!");
19
    }
20
21
}