| Total Complexity | 1 |
| Total Lines | 14 |
| Duplicated Lines | 0 % |
| 1 | from mock import Mock |
||
| 7 | class LinesMock(Mock): |
||
| 8 | def filter(self, type=None): |
||
|
1 ignored issue
–
show
|
|||
| 9 | return [Mock( |
||
| 10 | text="Cool cottage", |
||
| 11 | product=Mock( |
||
| 12 | type=Mock( |
||
| 13 | identifier="reservable" |
||
| 14 | ) |
||
| 15 | ), |
||
| 16 | extra_data={ |
||
| 17 | "reservation_start": "2016-01-01", |
||
| 18 | "persons": 3, |
||
| 19 | }, |
||
| 20 | quantity=4, |
||
| 21 | )] |
||
| 37 |
It is generally discouraged to redefine built-ins as this makes code very hard to read.