Examples of PersonRepository


Examples of org.springframework.data.neo4j.repositories.PersonRepository

    @Test
    public void testBasicRepositoryFunctionality() {
        startJavaBasedAppCtx();
        GraphDatabaseService graphDatabaseService = appCtx.getBean(GraphDatabaseService.class);
        PersonRepository personRepository = appCtx.getBean(PersonRepository.class);
        try (Transaction tx = graphDatabaseService.beginTx()) {
            Person person = new Person("Howdy",50);
            personRepository.save(person);
            assertNotNull(person.getId());
            tx.success();
        }
    }
View Full Code Here

Examples of org.springframework.data.repository.invoker.CrudRepositoryInvokerUnitTests.PersonRepository

    HashMap<String, String[]> parameters = new HashMap<String, String[]>();
    parameters.put("firstName", new String[] { "John" });

    Method method = PersonRepository.class.getMethod("findByFirstName", String.class, Pageable.class);
    PersonRepository repository = mock(PersonRepository.class);

    getInvokerFor(repository, expectInvocationOf(method)).invokeQueryMethod(method, parameters, null, null);
  }
View Full Code Here

Examples of org.springframework.data.repository.invoker.CrudRepositoryInvokerUnitTests.PersonRepository

    HashMap<String, String[]> parameters = new HashMap<String, String[]>();
    parameters.put("date", new String[] { "2013-07-18T10:49:00.000+02:00" });

    Method method = PersonRepository.class.getMethod("findByCreatedUsingISO8601Date", Date.class, Pageable.class);
    PersonRepository repository = mock(PersonRepository.class);

    getInvokerFor(repository, expectInvocationOf(method)).invokeQueryMethod(method, parameters, null, null);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.