MCPcopy Create free account
hub / github.com/dillo-browser/dillo / testStackAsQueue

Function testStackAsQueue

test/unit/containers.cc:131–145  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

129}
130
131void testStackAsQueue ()
132{
133 puts ("--- testStackAsQueue ---");
134
135 Stack<Integer> s (true);
136
137 for (int i = 1; i <= 10; i++)
138 s.pushUnder (new Integer (i));
139
140 while (s.size () > 0) {
141 Integer *i = s.getTop ();
142 printf ("%d\n", i->getValue ());
143 s.pop ();
144 }
145}
146
147int main (int argc, char *argv[])
148{

Callers 1

mainFunction · 0.85

Calls 5

pushUnderMethod · 0.45
sizeMethod · 0.45
getTopMethod · 0.45
getValueMethod · 0.45
popMethod · 0.45

Tested by

no test coverage detected