Take the 2008 Git User's Survey and help out! [ hide ]

ry / ebb fork watch download tarball
public
Description: web server
Homepage: http://ebb.rubyforge.org
Clone URL: git://github.com/ry/ebb.git
Search Repo:
ryah (author)
Wed Apr 09 05:15:08 -0700 2008
commit  9bc8da2c4cab2643f399f26dffdef1f48cdf6d7a
tree    86569ce7eac26c728e76c70cbc78ee0847d639d8
parent  1a53c2b86d8cb383167163cff4acc0bfaa344a86
ebb / test / test.py
100644 23 lines (17 sloc) 0.547 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import sys
sys.path.append('/Users/ry/projects/ebb/build/lib.macosx-10.3-ppc-2.5')
import ebb
# os.path.abspath(__file__)
 
def simple_app(environ):
  """Simplest possible application object"""
  status = '200 OK'
  headers = [('Content-type','text/plain')]
  body = ["Hello world!\n"]
  return([status, headers, body])
 
 
def simple_wsgi1_app(environ, start_response):
  status = '200 OK'
  headers = [('Content-type','text/plain')]
  body = ["Hello world!\n"]
  
  start_response(status, headers)
  return body
 
 
ebb.start_server(simple_wsgi1_app)