merged iterator test with stack test