@Test
public void getStateTest() throws Exception {

    // Setup:
    Model resources = MODEL_FACTORY.createModel();
    resources.add(VALUE_FACTORY.createIRI("http://example.com/example"), VALUE_FACTORY.createIRI(DCTERMS.TITLE.stringValue()), VALUE_FACTORY.createLiteral("Title"));
    State state = stateFactory.createNew(VALUE_FACTORY.createIRI("http://mobi.com/states/0"));
    state.setStateResource(Collections.singleton(VALUE_FACTORY.createIRI("http://example.com/example")));
    RepositoryConnection conn = repo.getConnection();
    conn.add(state.getModel());
    conn.add(resources);
    Model result = manager.getState(state.getResource());
    assertFalse(result.isEmpty());
    assertTrue(result.containsAll(resources));
    conn.close();
}