@Test
public void addJar() {

    // Mock resource loader
    final DataSourceResourceLoader resourceLoader = Mockito.mock(DataSourceResourceLoader.class);
    Mockito.when(resourceLoader.addJar(Mockito.anyString())).thenReturn(false, true);
    // Test adding jars
    final MockDataSetOptionsAccess mock = new MockDataSetOptionsAccess(resourceLoader);
    mock.addJar("file1.jar");
    mock.addJar("file2.jar");
    Assert.assertEquals(1, mock.getOptions().getJars().size());
    Assert.assertEquals("file2.jar", mock.getOptions().getJars().get(0));
}