Commit ab00e903ca9ab89d7b153f5e2e78937c86fb1bcd
1 parent
5f89545a
Add unit test for show_irf.py example script
Showing
2 changed files
with
17 additions
and
0 deletions
examples/Makefile.am
| @@ -32,6 +32,7 @@ scripts = README.md \ | @@ -32,6 +32,7 @@ scripts = README.md \ | ||
| 32 | pipeline_unbinned_disk.py \ | 32 | pipeline_unbinned_disk.py \ |
| 33 | pipeline_unbinned_mem.py \ | 33 | pipeline_unbinned_mem.py \ |
| 34 | show_butterfly.py \ | 34 | show_butterfly.py \ |
| 35 | + show_irf.py \ | ||
| 35 | show_model.py \ | 36 | show_model.py \ |
| 36 | show_pha.py \ | 37 | show_pha.py \ |
| 37 | show_pull_evolution.py \ | 38 | show_pull_evolution.py \ |
test/test_examples.py.in
| @@ -114,6 +114,8 @@ class Test(gammalib.GPythonTestSuite): | @@ -114,6 +114,8 @@ class Test(gammalib.GPythonTestSuite): | ||
| 114 | 'Test pipeline_unbinned_mem.py') | 114 | 'Test pipeline_unbinned_mem.py') |
| 115 | self.append(self.test_show_butterfly, | 115 | self.append(self.test_show_butterfly, |
| 116 | 'Test show_butterfly.py') | 116 | 'Test show_butterfly.py') |
| 117 | + self.append(self.test_show_irf, | ||
| 118 | + 'Test show_irf.py') | ||
| 117 | self.append(self.test_show_model, | 119 | self.append(self.test_show_model, |
| 118 | 'Test show_model.py') | 120 | 'Test show_model.py') |
| 119 | self.append(self.test_show_pha, | 121 | self.append(self.test_show_pha, |
| @@ -278,6 +280,20 @@ class Test(gammalib.GPythonTestSuite): | @@ -278,6 +280,20 @@ class Test(gammalib.GPythonTestSuite): | ||
| 278 | # Return | 280 | # Return |
| 279 | return | 281 | return |
| 280 | 282 | ||
| 283 | + # Test show_irf | ||
| 284 | + def test_show_irf(self): | ||
| 285 | + """ | ||
| 286 | + Test show_irf | ||
| 287 | + """ | ||
| 288 | + # Set arguments | ||
| 289 | + args = '-p example_show_irf.eps prod2 South_0.5h' | ||
| 290 | + | ||
| 291 | + # Execute script | ||
| 292 | + self._execute_python('show_irf', args=args) | ||
| 293 | + | ||
| 294 | + # Return | ||
| 295 | + return | ||
| 296 | + | ||
| 281 | # Test show_model | 297 | # Test show_model |
| 282 | def test_show_model(self): | 298 | def test_show_model(self): |
| 283 | """ | 299 | """ |