Plenty of unittests added. Works for me.
Details
- Reviewers
kparal tflink - Maniphest Tasks
- T751: Add additional dist-git style tasks namespace check to libtaskotron
- Commits
- rLTRNda14c4bba6ea: Add dist-git style tasks namespace check
Diff Detail
- Repository
- rLTRN libtaskotron
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
libtaskotron/directives/resultsdb_directive.py | ||
---|---|---|
32–35 | This should be amended to cover additional cases when we raise this. | |
258–261 | The process() method is getting really long, could this be separated into a standalone method? | |
263 | Please add a debug printout before breaking. | |
281 | Please add a debug printout before breaking. | |
290 | This should be pkg.%s. (a dot in the end), right? | |
293 | Can you add explanation where is the KeyError coming from? | |
294–296 | I don't like this very much. We're claiming here it is about namespace permissions, even when the original message is "Could not find task's git" (a completely different problem), or when the task tries to use a namespace we don't know about (also a different problem). Could we throw those errors right away, with specific error messages? | |
testing/test_resultsdb_directive.py | ||
339 | Why is this needed, isn't self.ref_arg_data regenerated before each test method start? |
Thanks, looks good.
testing/test_resultsdb_directive.py | ||
---|---|---|
339 | I still think you can save this one line from all your tests. |
This should be amended to cover additional cases when we raise this.