Exemplo n.º 1
0
 def test_add__without_captured_data(self):
     captured1 = Captured()
     captured2 = Captured("STDOUT", "STDERR", "LOG_OUTPUT")
     captured1.add(captured2)
     assert captured1.stdout == "STDOUT"
     assert captured1.stderr == "STDERR"
     assert captured1.log_output == "LOG_OUTPUT"
Exemplo n.º 2
0
 def test_add__without_captured_data(self):
     captured1 = Captured()
     captured2 = Captured("STDOUT", "STDERR", "LOG_OUTPUT")
     captured1.add(captured2)
     assert captured1.stdout == "STDOUT"
     assert captured1.stderr == "STDERR"
     assert captured1.log_output == "LOG_OUTPUT"
Exemplo n.º 3
0
    def test_add__with_captured_data(self):
        captured1 = Captured("stdout1", "stderr1", "log_output1")
        captured2 = Captured("STDOUT2", "STDERR2", "LOG_OUTPUT2")

        captured1.add(captured2)
        assert captured1.stdout == "stdout1\nSTDOUT2"
        assert captured1.stderr == "stderr1\nSTDERR2"
        assert captured1.log_output == "log_output1\nLOG_OUTPUT2"
Exemplo n.º 4
0
    def test_add__with_captured_data(self):
        captured1 = Captured("stdout1", "stderr1", "log_output1")
        captured2 = Captured("STDOUT2", "STDERR2", "LOG_OUTPUT2")

        captured1.add(captured2)
        assert captured1.stdout == "stdout1\nSTDOUT2"
        assert captured1.stderr == "stderr1\nSTDERR2"
        assert captured1.log_output == "log_output1\nLOG_OUTPUT2"