    @Test
    public void testTrueForMatchedPattern() {

        when(coconutView.getCoconutView()).thenReturn(coconutInput);
        when(coconutInput.getInput()).thenReturn("1234");
        when(coconutInput.getValidationRegex()).thenReturn("[0-9]+");
        when(coconutInput.getErrorMessages()).thenReturn("only numbers");
        boolean condition = CoconutValidator.areFieldsValid(coconutView);
        Assert.assertTrue(condition);
    }