Permalink
Browse files

Fix bug where Document is catched by Insert<TElement>(IEnumerable<TEl…

…ement> documents).
  • Loading branch information...
lanwin committed Mar 24, 2010
1 parent 5bf2ffb commit 2243bc63145abf6bfa9e4c58ea2ecda8e04002c1
View
@@ -1,42 +1,34 @@
-
-using System;
-using System.IO;
-using System.Net;
-using System.Net.Sockets;
-
-
-using NUnit.Framework;
-
-namespace MongoDB.Driver
-{
-
-
- [TestFixture()]
- public class TestB
- {
-
- [Test()]
- public void TestCase(){
- TcpClient client = new TcpClient();
- client.Connect("localhost", 27017);
- BufferedStream buff = new BufferedStream(client.GetStream());
- BinaryWriter writer = new BinaryWriter(buff);
-
- System.Text.UTF8Encoding encoding=new System.Text.UTF8Encoding();
- Byte[] msg = encoding.GetBytes("Hello MongoDB!");
-
-
- writer.Write(16 + msg.Length + 1);
- writer.Write(1);
- writer.Write(1);
- writer.Write(1000);
- writer.Write(msg);
- writer.Write((byte)0);
-
- writer.Flush();
- writer.Close();
- client.Close();
-
- }
- }
-}
+using System.IO;
+using System.Net.Sockets;
+using System.Text;
+using NUnit.Framework;
+
+namespace MongoDB.Driver
+{
+ [TestFixture]
+ public class TestB
+ {
+ [Test]
+ public void TestCase()
+ {
+ var client = new TcpClient();
+ client.Connect("localhost", 27017);
+ var buff = new BufferedStream(client.GetStream());
+ var writer = new BinaryWriter(buff);
+
+ var encoding = new UTF8Encoding();
+ var msg = encoding.GetBytes("Hello MongoDB!");
+
+ writer.Write(16 + msg.Length + 1);
+ writer.Write(1);
+ writer.Write(1);
+ writer.Write(1000);
+ writer.Write(msg);
+ writer.Write((byte)0);
+
+ writer.Flush();
+ writer.Close();
+ client.Close();
+ }
+ }
+}
Oops, something went wrong.

0 comments on commit 2243bc6

Please sign in to comment.