def test_change_username(self): ''' Test if it change a username ''' with patch('salt.modules.ilo.__execute_cmd', MagicMock(return_value={'Change username': {}})): self.assertDictEqual(ilo.change_username('Salt', 'SALT'), {'Change username': {}})
def test_change_username(self): """ Test if it change a username """ with patch( "salt.modules.ilo.__execute_cmd", MagicMock(return_value={"Change username": {}}), ): self.assertDictEqual(ilo.change_username("Salt", "SALT"), {"Change username": {}})
def test_change_username(self): ''' Test if it change a username ''' self.assertDictEqual(ilo.change_username('Salt', 'SALT'), {'Change username': {}})