Completed
Push — master ( b812a3...c78ccd )
by Thijs
10:26 queued 08:16
created

TransformsAccounts::fromDevOpsAccount()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 7
ccs 4
cts 4
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
3
namespace TestMonitor\DevOps\Transforms;
4
5
use TestMonitor\DevOps\Resources\Account;
6
7
trait TransformsAccounts
8
{
9
    /**
10
     * @param array $account
11
     * @return \TestMonitor\DevOps\Resources\Account
12
     */
13 1
    protected function fromDevOpsAccount(array $account): Account
14
    {
15 1
        return new Account(
16 1
            $account['AccountId'],
17 1
            $account['AccountName']
18
        );
19
    }
20
}
21