Пример #1
0
 def it_is_structured_text(self):
     function = Function("foo")
     function.mov("rax", 1)
     str(function) |should| equal_to("foo:\n\tmov\trax, 1\n\tret")
Пример #2
0
 def it_has_instructions(self):
     function = Function(".text")
     function.mov("rax", 42)
     function |should| have(1).instructions
     function.instructions |should| include("\tmov\trax, 42")