public void addData(String key, String value) throws InvalidSCMRevisionDataException {
        validateDataKey(key);
        data.put(key, value);
    }
@Test
    public void shouldThrowExceptionWhenDataKeyIsNullOrEmpty() throws Exception {
        SCMRevision scmRevision = new SCMRevision("rev123", new Date(), "loser", null, null, null);
        try {
            scmRevision.addData(null, "value");
        } catch (InvalidSCMRevisionDataException e) {
            assertThat(e.getMessage(), is("Key names cannot be null or empty."));
        }
        try {
            scmRevision.addData("", "value");
        } catch (InvalidSCMRevisionDataException e) {
            assertThat(e.getMessage(), is("Key names cannot be null or empty."));
        }
    }