add manual testing category

This commit is contained in:
Alan Hamlett 2018-04-07 16:31:39 -07:00
parent 358308c993
commit f2b8776e21
4 changed files with 11 additions and 8 deletions

View File

@ -31,9 +31,9 @@ optional arguments:
Entity type for this heartbeat. Can be "file",
"domain" or "app". Defaults to "file".
--category CATEGORY Category of this heartbeat activity. Can be "coding",
"building", "debugging", "running tests", "browsing",
"code reviewing", "designing" or "indexing". Defaults
to "coding".
"building", "indexing", "debugging", "running tests",
"manual testing", "browsing", "code reviewing" or
"designing". Defaults to "coding".
--proxy PROXY Optional proxy configuration. Supports HTTPS and SOCKS
proxies. For example: https://user:pass@host:port or
socks5://user:pass@host:port or domain\user:pass

View File

@ -505,12 +505,13 @@ class ArgumentsTestCase(TestCase):
valid_categories = [
'coding',
'building',
'indexing',
'debugging',
'running tests',
'manual testing',
'browsing',
'code reviewing',
'designing',
'indexing',
]
for category in valid_categories:

View File

@ -87,9 +87,10 @@ def parse_arguments():
parser.add_argument('--category', dest='category',
action=StoreWithoutQuotes,
help='Category of this heartbeat activity. Can be ' +
'"coding", "building", "debugging", ' +
'"running tests", "browsing", ' +
'"code reviewing", "designing" or "indexing". ' +
'"coding", "building", "indexing", ' +
'"debugging", "running tests", ' +
'"manual testing", "browsing", ' +
'"code reviewing" or "designing". ' +
'Defaults to "coding".')
parser.add_argument('--proxy', dest='proxy', action=StoreWithoutQuotes,
help='Optional proxy configuration. Supports HTTPS '+

View File

@ -63,12 +63,13 @@ class Heartbeat(object):
allowed_categories = [
'coding',
'building',
'indexing',
'debugging',
'running tests',
'manual testing',
'browsing',
'code reviewing',
'designing',
'indexing',
]
if self.category not in allowed_categories:
self.category = None