예제 #1
0
        public void TestRemoveNode()
        {
            Node testNode = new Node();

            testNode.Id        = -1;
            testNode.Latitude  = 0;
            testNode.Longitude = 0;

            var source = new MemoryDataSource();

            source.AddNode(testNode);

            // test if the node is actually there.
            Assert.AreEqual(testNode, source.GetNode(-1));

            // remove the node.
            source.RemoveNode(-1);

            // test if the node is actually gone.
            Assert.IsNull(source.GetNode(-1));
        }