aboutsummaryrefslogtreecommitdiffstats
path: root/test.py
diff options
context:
space:
mode:
Diffstat (limited to 'test.py')
-rw-r--r--test.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/test.py b/test.py
index c7bc552..8af676b 100644
--- a/test.py
+++ b/test.py
@@ -1,8 +1,8 @@
import urllib
-assert "Hello World!" == urllib.urlopen('http://localhost:8080').read()
-assert "About Flask example." == urllib.urlopen('http://localhost:8080/about').read()
-assert 404 == urllib.urlopen('http://localhost:8080/list').getcode()
-assert "3 bottles of beer!" == urllib.urlopen('http://localhost:8080/hello/3').read()
-assert "100 bottles of beer!" == urllib.urlopen('http://localhost:8080/hello/100').read()
-assert "" == urllib.urlopen('http://localhost:8080/hello/500').read()
-assert 400 == urllib.urlopen('http://localhost:8080/hello/500').getcode()
+assert "Hello World!" == urllib.urlopen('http://localhost:18080').read()
+assert "About Flask example." == urllib.urlopen('http://localhost:18080/about').read()
+assert 404 == urllib.urlopen('http://localhost:18080/list').getcode()
+assert "3 bottles of beer!" == urllib.urlopen('http://localhost:18080/hello/3').read()
+assert "100 bottles of beer!" == urllib.urlopen('http://localhost:18080/hello/100').read()
+assert 400 == urllib.urlopen('http://localhost:18080/hello/500').getcode()
+assert "3" == urllib.urlopen('http://localhost:18080/add_json', data='{"a":1,"b":2}').read()