# The main page, `index.html`, is served dynamicly with `MyAction`.
# The rest of the Web site fetches files from the local directory
# `www/hello_world/`.
-module nitcorn_hello_world
+module nitcorn_hello_world is example
import nitcorn
# Serve everything else with a standard `FileServer` with a root at "www/hello_world/"
vh.routes.add new Route(null, new FileServer("www/hello_world/"))
-# Avoid executing when running tests
-if "NIT_TESTING".environ == "true" then exit 0
-
var factory = new HttpFactory.and_libevent
factory.config.virtual_hosts.add vh
factory.run