Test that method :meth:`~pythonforandroid.distribution.Distribution.delete` is called once with the proper arguments.
(self, mock_rmdir)
| 93 | |
| 94 | @mock.patch("pythonforandroid.distribution.rmdir") |
| 95 | def test_delete(self, mock_rmdir): |
| 96 | """Test that method |
| 97 | :meth:`~pythonforandroid.distribution.Distribution.delete` is |
| 98 | called once with the proper arguments.""" |
| 99 | self.setUp_distribution_with_bootstrap( |
| 100 | Bootstrap().get_bootstrap("sdl2", self.ctx) |
| 101 | ) |
| 102 | self.ctx.bootstrap.distribution.delete() |
| 103 | mock_rmdir.assert_called_once_with( |
| 104 | self.ctx.bootstrap.distribution.dist_dir |
| 105 | ) |
| 106 | |
| 107 | @mock.patch("pythonforandroid.distribution.exists") |
| 108 | def test_get_distribution_no_name(self, mock_exists): |
nothing calls this directly
no test coverage detected