@@ -0,0 +1,1333 @@
+package com.fsck.k9.mail.store.webdav;%0A%0Aimport com.fsck.k9.mail.MessagingException;%0A%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0Aimport org.junit.runner.RunWith;%0Aimport org.mockito.Mock;%0Aimport org.mockito.MockitoAnnotations;%0Aimport org.robolectric.RobolectricTestRunner;%0Aimport org.robolectric.annotation.Config;%0A%0Aimport java.util.Collections;%0A%0Aimport static org.mockito.Mockito.mock;%0Aimport static org.mockito.Mockito.verify;%0Aimport static org.mockito.Mockito.when;%0A%0A@RunWith(RobolectricTestRunner.class)%0A@Config(manifest = Config.NONE, sdk = 21)%0Apublic class WebDavMessageTest %7B%0A%0A    private WebDavMessage message;%0A    @Mock%0A    private WebDavFolder mockFolder;%0A    @Mock%0A    private WebDavStore mockStore;%0A    @Mock%0A    private WebDavFolder mockTrashFolder;%0A%0A    @Before%0A    public void before() %7B%0A        MockitoAnnotations.initMocks(this);%0A        when(mockFolder.getName()).thenReturn(%22Inbox%22);%0A        message = new WebDavMessage(%22message1%22, mockFolder);%0A    %7D%0A%0A    @Test%0A    public void delete_asks_folder_to_delete_message() throws MessagingException %7B%0A        when(mockFolder.getStore()).thenReturn(mockStore);%0A        when(mockStore.getFolder(%22Trash%22)).thenReturn(mockTrashFolder);%0A        message.delete(%22Trash%22);%0A        verify(mockFolder).moveMessages(Collections.singletonList(message), mockTrashFolder);%0A    %7D%0A%7D%0A

Create test infrastructure for WebDavMessage