Completed
Push — master ( 06b292...adafac )
by Nicolai
02:22
created

BaseIntegrationCest   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 42
Duplicated Lines 0 %

Coupling/Cohesion

Components 2
Dependencies 3

Importance

Changes 0
Metric Value
dl 0
loc 42
rs 10
c 0
b 0
f 0
wmc 4
lcom 2
cbo 3

4 Methods

Rating   Name   Duplication   Size   Complexity  
A _beforeSuite() 0 6 1
A _before() 0 6 1
A _after() 0 4 1
A _failed() 0 4 1
1
<?php
2
3
4
namespace SmartWeb\ModuleTesting;
5
6
use Codeception\Scenario;
7
use Illuminate\Support\Facades\Storage;
8
use SmartWeb\ModuleTesting\Util\UsesDisk;
9
10
11
/**
12
 * Class BaseIntegrationTest
13
 *
14
 * @package SmartWeb\Testing
15
 */
16
abstract class BaseIntegrationCest extends BaseCodeceptionCest
17
{
18
    
19
    use UsesDisk;
20
    
21
    /**
22
     * @inheritDoc
23
     */
24
    public function _beforeSuite(array $settings = [])
25
    {
26
        parent::_beforeSuite($settings);
27
        
28
        Storage::fake(static::$disk);
29
    }
30
    
31
    /**
32
     * @inheritDoc
33
     */
34
    public function _before(Scenario $S)
35
    {
36
        $this->scenario = $S;
37
        
38
        $this->backupItems();
39
    }
40
    
41
    /**
42
     * @inheritDoc
43
     */
44
    public function _after(Scenario $S)
0 ignored issues
show
Unused Code introduced by
The parameter $S is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
45
    {
46
        $this->restoreItems();
47
    }
48
    
49
    /**
50
     * @inheritDoc
51
     */
52
    public function _failed($fail)
0 ignored issues
show
Unused Code introduced by
The parameter $fail is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
53
    {
54
    
55
    }
56
    
57
}