Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

return an error

  • Loading branch information...
commit dc37c7fbb1193081afd0a7ca64a2b92ac0481386 1 parent 0502113
@kung-fu-tzu authored
View
2  js/Handler.js
@@ -82,3 +82,5 @@ require('tests/standart-classes.js')
require('demos/request-headers-out.js')
require('demos/delayed-output.js')
+require('demos/return-an-error.js')
+require('demos/return-error-500.js')
View
8 js/demos/return-an-error.js
@@ -0,0 +1,8 @@
+;(function(){
+
+NginxDemos.returnAnError = function (r)
+{
+ return Nginx.ERROR
+}
+
+})();
View
8 js/demos/return-error-500.js
@@ -0,0 +1,8 @@
+;(function(){
+
+NginxDemos.returnError500 = function (r)
+{
+ return Nginx.HTTP_INTERNAL_SERVER_ERROR
+}
+
+})();
View
2  run-tests
@@ -61,6 +61,8 @@ curl $OPTS "http://127.0.0.1:19090/run/standart-classes"
curl $OPTS "http://127.0.0.1:19090/demo/request-headers-out"
curl $OPTS "http://127.0.0.1:19090/demo/delayed-output"
+curl $OPTS "http://127.0.0.1:19090/demo/return-an-error"
+curl $OPTS "http://127.0.0.1:19090/demo/return-error-500"
# ab -kc 20 -n 200 http://127.0.0.1:19090/run/file
Please sign in to comment.
Something went wrong with that request. Please try again.