ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/ccscs20/UnitTest.cpp
(Generate patch)

Comparing UnitTest.cpp (file contents):
Revision 1 by Douglas Thrift, 2004-05-12T23:36:53-07:00 vs.
Revision 8 by Douglas Thrift, 2004-05-14T11:26:01-07:00

# Line 4 | Line 4
4   //
5   // $Id$
6  
7 + #include <iostream>
8 + #include <string>
9   #include "DoublyLinkedList.hpp"
10  
11 + using namespace std;
12 +
13   int main(int argc, char* argv[])
14   {
15 +        cout.setf(ios_base::boolalpha);
16 +
17          DoublyLinkedList<int> list;
18  
19 +        list.addFront(1);
20 +        list.addBack(2);
21 +        list.addFront(4);
22 +        list.addBack(5);
23 +
24 +        // 4 1 2 5
25 +
26 +        cout << "list.contains(1) = " << list.contains(1) << '\n'
27 +                << "list.contains(2) = " << list.contains(2) << '\n'
28 +                << "list.contains(3) = " << list.contains(3) << '\n'
29 +                << "list.contains(4) = " << list.contains(4) << '\n'
30 +                << "list.contains(5) = " << list.contains(5) << '\n';
31 +
32 +        list.removeFirst(2);
33 +
34 +        // 4 1 5
35 +
36 +        cout << "list.contains(2) = " << list.contains(2) << '\n'
37 +                << "list.contains(5) = " << list.contains(5) << '\n';
38 +
39 +        for (Iterator<int> itor(list.iterator()); !itor.end(); itor++)
40 +        {
41 +                cout << *itor << '\n';
42 +        }
43 +
44          return 0;
45   }

Comparing UnitTest.cpp (property svn:eol-style):
Revision 1 by Douglas Thrift, 2004-05-12T23:36:53-07:00 vs.
Revision 8 by Douglas Thrift, 2004-05-14T11:26:01-07:00

# Line 0 | Line 1
1 + native

Comparing UnitTest.cpp (property svn:keywords):
Revision 1 by Douglas Thrift, 2004-05-12T23:36:53-07:00 vs.
Revision 8 by Douglas Thrift, 2004-05-14T11:26:01-07:00

# Line 0 | Line 1
1 + Id

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines