Esempio n. 1
0
 def test_remove_package(self):
     '''
         Test uninstalling a package with DISM
     '''
     mock = MagicMock()
     with patch.dict(dism.__salt__, {'cmd.run_all': mock}):
         dism.remove_package("test")
         mock.assert_called_once_with(
             ['DISM', '/Quiet', '/Online', '/Remove-Package', '/NoRestart',
              '/PackagePath:test'])
Esempio n. 2
0
 def test_remove_package(self):
     '''
         Test uninstalling a package with DISM
     '''
     mock = MagicMock()
     with patch.dict(dism.__salt__, {'cmd.run_all': mock}):
         dism.remove_package("test")
         mock.assert_called_once_with([
             'DISM', '/Quiet', '/Online', '/Remove-Package', '/NoRestart',
             '/PackagePath:test'
         ])
Esempio n. 3
0
def test_remove_package():
    """
    Test uninstalling a package with DISM
    """
    mock = MagicMock()
    with patch.dict(dism.__salt__, {"cmd.run_all": mock}):
        dism.remove_package("test")
        mock.assert_called_once_with([
            dism.bin_dism,
            "/Quiet",
            "/Online",
            "/Remove-Package",
            "/NoRestart",
            "/PackagePath:test",
        ])