File: names.py

package info (click to toggle)
python-flaky 3.8.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 332 kB
  • sloc: python: 1,320; makefile: 11; sh: 10
file content (23 lines) | stat: -rw-r--r-- 630 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class FlakyNames:
    """
    Names of flaky attributes that will be added to flaky tests
    """
    CURRENT_ERRORS = '_flaky_current_errors'
    CURRENT_RUNS = '_flaky_current_runs'
    CURRENT_PASSES = '_flaky_current_passes'
    MAX_RUNS = '_flaky_max_runs'
    MIN_PASSES = '_flaky_min_passes'
    RERUN_FILTER = '_flaky_rerun_filter'

    def items(self):
        return (
            self.CURRENT_ERRORS,
            self.CURRENT_PASSES,
            self.CURRENT_RUNS,
            self.MAX_RUNS,
            self.MIN_PASSES,
            self.RERUN_FILTER,
        )

    def __iter__(self):
        yield from self.items()