예제 #1
0
 def test_split_commands(self):
     """ Test that commands are indeed individually split."""
     i = Interpreter()
     test_atoms = [('(1\n + 1)', ),
                   ('1', '1', ),
                   ]
     for atoms in test_atoms:
         atoms = [atom.rstrip() + '\n' for atom in atoms]
         self.assertEquals(i.split_commands(''.join(atoms)),atoms)
예제 #2
0
 def test_ticket364347(self):
     """Test for ticket 364347."""
     i = Interpreter()
     i.split_commands('str("a\\nb")')