GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — CursorTest: adapt to changed invalid ID error message · Hancony/objectbox-java@d3b2fad

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • tests/objectbox-java-test/src/test/java/io/objectbox
    • CursorTest.java
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎tests/objectbox-java-test/src/test/java/io/objectbox/CursorTest.java‎

Copy file name to clipboardExpand all lines: tests/objectbox-java-test/src/test/java/io/objectbox/CursorTest.java
+11-4Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2017 ObjectBox Ltd. All rights reserved.
2+
* Copyright 2017-2024 ObjectBox Ltd. All rights reserved.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -16,13 +16,20 @@
1616

1717
package io.objectbox;
1818

19-
import io.objectbox.annotation.IndexType;
2019
import org.junit.Test;
2120

2221
import java.util.concurrent.CountDownLatch;
2322
import java.util.concurrent.TimeUnit;
2423

25-
import static org.junit.Assert.*;
24+
import io.objectbox.annotation.IndexType;
25+
26+
27+
import static org.junit.Assert.assertEquals;
28+
import static org.junit.Assert.assertFalse;
29+
import static org.junit.Assert.assertNotNull;
30+
import static org.junit.Assert.assertNull;
31+
import static org.junit.Assert.assertThrows;
32+
import static org.junit.Assert.assertTrue;
2633

2734
public class CursorTest extends AbstractObjectBoxTest {
2835

@@ -60,7 +67,7 @@ public void testPutEntityWithInvalidId() {
6067
IllegalArgumentException ex = assertThrows(IllegalArgumentException.class,
6168
() -> cursor.put(entity));
6269
assertEquals(ex.getMessage(), "ID is higher or equal to internal ID sequence: 777 (vs. 1)." +
63-
" Use ID 0 (zero) to insert new entities.");
70+
" Use ID 0 (zero) to insert new objects.");
6471
} finally {
6572
// Always clean up, even if assertions fail, to avoid misleading clean-up errors.
6673
cursor.close();

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.