Completed
Push — develop ( 604c57...dfb4a1 )
by Jace
8s
created

describe_detected()   A

Complexity

Conditions 3

Size

Total Lines 12

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 3
dl 0
loc 12
rs 9.4285
c 1
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A when_on_ci() 0 4 1
A when_off_ci() 0 5 1
1
# pylint: disable=missing-docstring,unused-variable,unused-argument,expression-not-assigned,singleton-comparison
0 ignored issues
show
introduced by
Bad option value 'singleton-comparison'
Loading history...
2
3
from expecter import expect
0 ignored issues
show
Configuration introduced by
The import expecter could not be resolved.

This can be caused by one of the following:

1. Missing Dependencies

This error could indicate a configuration issue of Pylint. Make sure that your libraries are available by adding the necessary commands.

# .scrutinizer.yml
before_commands:
    - sudo pip install abc # Python2
    - sudo pip3 install abc # Python3
Tip: We are currently not using virtualenv to run pylint, when installing your modules make sure to use the command for the correct version.

2. Missing __init__.py files

This error could also result from missing __init__.py files in your module folders. Make sure that you place one file in each sub-folder.

Loading history...
4
5
from coveragespace import services
6
7
8
def describe_detected():
9
10
    def when_off_ci(monkeypatch):
11
        monkeypatch.delenv('TRAVIS', raising=False)
12
        monkeypatch.delenv('APPVEYOR', raising=False)
13
14
        expect(services.detected()) == False
15
16
    def when_on_ci(monkeypatch):
17
        monkeypatch.setenv('TRAVIS', 'true')
18
19
        expect(services.detected()) == True
20