def test_delete_staticsite_domain_with_resourcegroup(self):
        delete_staticsite_domain(self.mock_cmd, self.name1, self.hostname1,
                                 self.rg1)

        self.staticapp_client.delete_static_site_custom_domain.assert_called_once_with(
            resource_group_name=self.rg1,
            name=self.name1,
            domain_name=self.hostname1)
    def test_delete_staticsite_domain_without_resourcegroup(self):
        self.staticapp_client.list.return_value = [self.app1, self.app2]

        delete_staticsite_domain(self.mock_cmd, self.name1, self.hostname1)

        self.staticapp_client.delete_static_site_custom_domain.assert_called_once_with(
            resource_group_name=self.rg1,
            name=self.name1,
            domain_name=self.hostname1)