blob: 624422ed5889ec8c9836a23888994d634becdb3e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
"""
Public API for extending Abrek
"""
from abc import abstractmethod
class ITest(object):
"""
Abrek test.
Something that can be installed and invoked by abre.
"""
@abstractmethod
def install(self):
"""
Install the test suite.
This creates an install directory under the user's XDG_DATA_HOME
directory to mark that the test is installed. The installer's
install() method is then called from this directory to complete any
test specific install that may be needed.
"""
@abstractmethod
def uninstall(self):
"""
Uninstall the test suite.
Uninstalling just recursively removes the test specific directory under
the user's XDG_DATA_HOME directory. This will both mark the test as
removed, and clean up any files that were downloaded or installed under
that directory. Dependencies are intentionally not removed by this.
"""
@abstractmethod
def run(self, quiet=False):
# TODO: Document me
pass
@abstractmethod
def parse(self, resultname):
# TODO: Document me
pass
|