[Zope3-checkins] CVS: Zope3/src/zope/app/tests - test_zapi.py:1.1

Jim Fulton jim@zope.com
Fri, 23 May 2003 18:18:14 -0400


Update of /cvs-repository/Zope3/src/zope/app/tests
In directory cvs.zope.org:/tmp/cvs-serv20182/src/zope/app/tests

Added Files:
	test_zapi.py 
Log Message:
Began the implementation of the zapi convenience module.


=== Added File Zope3/src/zope/app/tests/test_zapi.py ===
##############################################################################
#
# Copyright (c) 2003 Zope Corporation and Contributors.
# All Rights Reserved.
#
# This software is subject to the provisions of the Zope Public License,
# Version 2.0 (ZPL).  A copy of the ZPL should accompany this distribution.
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
# FOR A PARTICULAR PURPOSE.
#
##############################################################################
"""Test directly implemented functions in zapi

$Id: test_zapi.py,v 1.1 2003/05/23 22:18:13 jim Exp $
"""

from zope.testing.doctestunit import DocTestSuite
from zope.proxy.context import ContextWrapper
from zope.app import zapi

def test_name():
    """
    >>> ob = []
    >>> zapi.name(ob)
    >>> ob = zapi.ContextWrapper(ob, None, name='bob')
    >>> zapi.name(ob)
    'bob'
    """

def test_suite(): return DocTestSuite()
if __name__ == '__main__': unittest.main()