File tree Expand file tree Collapse file tree
driver-compat/src/test/unit/com/mongodb Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -248,59 +248,4 @@ public void testClose() {
248248 // all good
249249 }
250250 }
251-
252- @ Test
253- public void testDBDecoder () {
254- cursor .setDecoderFactory (new MyDBDecoderFactory ());
255- final DBObject objectFromDecoder = new BasicDBObject ("a" , 1 );
256- assertThat (cursor .toArray (), everyItem (is (objectFromDecoder )));
257- }
258-
259- static class MyDBDecoder implements DBDecoder {
260-
261- @ Override
262- public DBObject decode (InputStream in , DBCollection collection ) throws IOException {
263- return new BasicDBObject ("a" , 1 );
264- }
265-
266- @ Override
267- public DBCallback getDBCallback (DBCollection collection ) {
268- return null ; //TODO
269- }
270-
271- @ Override
272- public DBObject decode (byte [] bytes , DBCollection collection ) {
273- return new BasicDBObject ("a" , 1 ); //TODO
274- }
275-
276- @ Override
277- public BSONObject readObject (byte [] bytes ) {
278- return null ; //TODO
279- }
280-
281- @ Override
282- public BSONObject readObject (InputStream in ) throws IOException {
283- return null ; //TODO
284- }
285-
286- @ Override
287- public int decode (byte [] bytes , BSONCallback callback ) {
288- return 0 ; //TODO
289- }
290-
291- @ Override
292- public int decode (InputStream in , BSONCallback callback ) throws IOException {
293- return 0 ; //TODO
294- }
295- }
296- static class MyDBDecoderFactory implements DBDecoderFactory {
297-
298- @ Override
299- public DBDecoder create () {
300- return new MyDBDecoder ();
301- }
302- }
303-
304-
305-
306251}
You can’t perform that action at this time.
0 commit comments