@@ -0,0 +1,1661 @@
+package uk.gov.register.core;%0A%0Aimport org.flywaydb.core.Flyway;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0Aimport org.skife.jdbi.v2.DBI;%0Aimport uk.gov.register.configuration.ConfigManager;%0Aimport uk.gov.register.exceptions.NoSuchConfigException;%0A%0Aimport java.io.IOException;%0Aimport java.util.Optional;%0A%0Aimport static org.mockito.Mockito.*;%0A%0Apublic class RegisterContextTest %7B%0A    private RegisterName registerName;%0A    private ConfigManager configManager;%0A    private DBI dbi;%0A    private Flyway flyway;%0A%0A    @Before%0A    public void setup() %7B%0A        registerName = new RegisterName(%22register%22);%0A        configManager = mock(ConfigManager.class, RETURNS_DEEP_STUBS);%0A        dbi = mock(DBI.class);%0A        flyway = mock(Flyway.class);%0A    %7D%0A%0A    @Test%0A    public void resetRegister_shouldNotResetRegister_whenEnableRegisterDataDeleteIsDisabled() throws IOException, NoSuchConfigException %7B%0A        RegisterContext context = new RegisterContext(registerName, configManager, dbi, flyway, Optional.empty(), false, false);%0A        context.resetRegister();%0A%0A        verify(flyway, never()).clean();%0A        verify(configManager, never()).refreshConfig();%0A        verify(flyway, never()).migrate();%0A    %7D%0A%0A    @Test%0A    public void resetRegister_shouldResetRegister_whenEnableRegisterDataDeleteIsEnabled() throws IOException, NoSuchConfigException %7B%0A        RegisterContext context = new RegisterContext(registerName, configManager, dbi, flyway, Optional.empty(), true, false);%0A        context.resetRegister();%0A%0A        verify(flyway, times(1)).clean();%0A        verify(configManager, times(1)).refreshConfig();%0A        verify(flyway, times(1)).migrate();%0A    %7D%0A%7D

Add tests for resetRegister method in RegisterContext