mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
tests: Add taskrc_content property
This commit is contained in:
parent
dc0502dd9f
commit
75cf742a55
1 changed files with 9 additions and 0 deletions
|
@ -137,6 +137,15 @@ class Task(object):
|
||||||
cmd = (self.taskw, "config", "--", var, value)
|
cmd = (self.taskw, "config", "--", var, value)
|
||||||
return run_cmd_wait(cmd, env=self.env)
|
return run_cmd_wait(cmd, env=self.env)
|
||||||
|
|
||||||
|
@property
|
||||||
|
def taskrc_content(self):
|
||||||
|
"""
|
||||||
|
Returns the contents of the taskrc file.
|
||||||
|
"""
|
||||||
|
|
||||||
|
with open(self.taskrc, "r") as f:
|
||||||
|
return f.readlines()
|
||||||
|
|
||||||
def runSuccess(self, args=(), input=None, merge_streams=False,
|
def runSuccess(self, args=(), input=None, merge_streams=False,
|
||||||
timeout=1):
|
timeout=1):
|
||||||
"""Invoke task with given arguments and fail if exit code != 0
|
"""Invoke task with given arguments and fail if exit code != 0
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue