コード例 #1
0
    @Test
    public void shouldPutObjectsWithoutTypeMappingWithTransactionAsObservable() {
      final PutObjectsStub putStub =
          PutObjectsStub.newPutStubForMultipleObjectsWithoutTypeMappingWithTransaction();

      final Observable<PutResults<TestItem>> observable =
          putStub
              .storIOSQLite
              .put()
              .objects(putStub.items)
              .useTransaction(true)
              .withPutResolver(putStub.putResolver)
              .prepare()
              .asRxObservable();

      putStub.verifyBehaviorForMultipleObjects(observable);
    }
コード例 #2
0
    @Test
    public void shouldPutObjectsWithoutTypeMappingWithTransactionBlocking() {
      final PutObjectsStub putStub =
          PutObjectsStub.newPutStubForMultipleObjectsWithoutTypeMappingWithTransaction();

      final PutResults<TestItem> putResults =
          putStub
              .storIOSQLite
              .put()
              .objects(putStub.items)
              .useTransaction(true)
              .withPutResolver(putStub.putResolver)
              .prepare()
              .executeAsBlocking();

      putStub.verifyBehaviorForMultipleObjects(putResults);
    }