NodeDeployTask { @VisibleForTesting boolean isValidEmail(String email) { return (email != null && email.matches(".*@.*\\..*")); } NodeDeployTask(TorqueNodeDeployment torqueNodeDeployment, int nodeNumber,
            TorqueNodeConfiguration nodeConfiguration, TorqueConfiguration torqueConfiguration); void execute(); String base64Encode(String toEncode);  }
@Test public void isValidEmail() { assertThat(nodeDeployTask.isValidEmail(null), is(false)); assertThat(nodeDeployTask.isValidEmail(""), is(false)); assertThat(nodeDeployTask.isValidEmail("test"), is(false)); assertThat(nodeDeployTask.isValidEmail("test.test.com"), is(false)); assertThat(nodeDeployTask.isValidEmail("test@examplecom"), is(false)); assertThat(nodeDeployTask.isValidEmail("test.test@examplecom"), is(false)); assertThat(nodeDeployTask.isValidEmail("test@example.com"), is(true)); assertThat(nodeDeployTask.isValidEmail("test.test@example.com"), is(true)); }