parameters: (name, transition, stack, buf, deps,
                ex_stack, ex_buf, ex_deps)
docstring: Tests that a single parse step returns the expected output
docstring_summary: Tests that a single parse step returns the expected output
docstring_tokens: Tests that a single parse step returns the expected output
function: def test_step(name, transition, stack, buf, deps,
                ex_stack, ex_buf, ex_deps):
      """Tests that a single parse step returns the expected output"""
      pp = PartialParse([])
      pp.stack, pp.buffer, pp.dependencies = stack, buf, deps
  
      pp.parse_step(transition)
      stack, buf, deps = (tuple(pp.stack), tuple(pp.buffer), tuple(sorted(pp.dependencies)))
      assert stack == ex_stack, \
          "{:} test resulted in stack {:}, expected {:}".format(name, stack, ex_stack)
      assert buf == ex_buf, \
          "{:} test resulted in buffer {:}, expected {:}".format(name, buf, ex_buf)
      assert deps == ex_deps, \
          "{:} test resulted in dependency list {:}, expected {:}".format(name, deps, ex_deps)
      print("{:} test passed!".format(name))
function_tokens: def test_step ( name , transition , stack , buf , deps , ex_stack , ex_buf , ex_deps ) : pp = PartialParse ( [ ] ) pp . stack , pp . buffer , pp . dependencies = stack , buf , deps pp . parse_step ( transition ) stack , buf , deps = ( tuple ( pp . stack ) , tuple ( pp . buffer ) , tuple ( sorted ( pp . dependencies ) ) ) assert stack == ex_stack , "{:} test resulted in stack {:}, expected {:}" . format ( name , stack , ex_stack ) assert buf == ex_buf , "{:} test resulted in buffer {:}, expected {:}" . format ( name , buf , ex_buf ) assert deps == ex_deps , "{:} test resulted in dependency list {:}, expected {:}" . format ( name , deps , ex_deps ) print ( "{:} test passed!" . format ( name ) )