Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

test => test_envoy

  • Loading branch information...
commit c449de960421fc2e01d08a97e235cc55dde94805 1 parent 558cb92
@kennethreitz authored
Showing with 7 additions and 7 deletions.
  1. +7 −7 test.py → test_envoy.py
View
14 test.py → test_envoy.py
@@ -2,19 +2,19 @@
import envoy
class SimpleTest(unittest.TestCase):
-
- def testInput(self):
+
+ def test_input(self):
r = envoy.run("sed s/i/I/g", "Hi")
- self.assertEqual(r.std_out, "HI")
+ self.assertEqual(r.std_out.rstrip(), "HI")
self.assertEqual(r.status_code, 0)
-
- def testPipe(self):
+
+ def test_pipe(self):
r = envoy.run("echo -n 'hi'| tr [:lower:] [:upper:]")
self.assertEqual(r.std_out, "HI")
self.assertEqual(r.status_code, 0)
- def testTimeout(self):
- r = envoy.run("yes | head", timeout=1)
+ def test_timeout(self):
+ r = envoy.run('yes | head', timeout=1)
self.assertEqual(r.std_out, 'y\ny\ny\ny\ny\ny\ny\ny\ny\ny\n')
self.assertEqual(r.status_code, 0)
Please sign in to comment.
Something went wrong with that request. Please try again.