/[gnue]/gnue-appserver/src/classrep/mtest.py
ViewVC logotype

Diff of /gnue-appserver/src/classrep/mtest.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by reinhard, Fri Aug 8 19:33:51 2003 UTC revision 1.4 by jvetter, Thu Sep 18 15:14:10 2003 UTC
# Line 1  Line 1 
1  # Testing unit for Class Repository  # GNU Enterprise Application Server - Testing unit for Class Repository
2    #
3    # Copyright 2003 Free Software Foundation
4    #
5    # This file is part of GNU Enterprise.
6    #
7    # GNU Enterprise is free software; you can redistribute it
8    # and/or modify it under the terms of the GNU General Public
9    # License as published by the Free Software Foundation; either
10    # version 2, or (at your option) any later version.
11    #
12    # GNU Enterprise is distributed in the hope that it will be
13    # useful, but WITHOUT ANY WARRANTY; without even the implied
14    # warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15    # PURPOSE. See the GNU General Public License for more details.
16    #
17    # You should have received a copy of the GNU General Public
18    # License along with program; see the file COPYING. If not,
19    # write to the Free Software Foundation, Inc., 59 Temple Place
20    # - Suite 330, Boston, MA 02111-1307, USA.
21    #
22    # $Id$
23    #
24    # This testing unit dumps some values of class definitions.
25    #
26    
27  from language import App  from language import App
28  from gnue.appserver import classrep  from gnue.appserver import classrep
# Line 16  def dumpClass (aName): Line 40  def dumpClass (aName):
40    print "Fullname:", aClass.fullName    print "Fullname:", aClass.fullName
41    print "Id      :", aClass.gnue_id    print "Id      :", aClass.gnue_id
42    print "Module  :", aClass.module.fullName    print "Module  :", aClass.module.fullName
43      print "Comment :", aClass.gnue_comment
44    
45    print "\nProperties:"    print "\nProperties:"
46    
# Line 28  def dumpClass (aName): Line 53  def dumpClass (aName):
53    
54    print "End of dump for '%s'\n" % aName    print "End of dump for '%s'\n" % aName
55    
56    # dump some class definitions
57  dumpClass ('address_person')  dumpClass ('address_person')
58  dumpClass ('gnue_class')  dumpClass ('gnue_class')
59    
# Line 36  x = classrep.classes ['gnue_property'] Line 62  x = classrep.classes ['gnue_property']
62  y = x.findProp ('gnue_name')  y = x.findProp ('gnue_name')
63  print "Fullname:", y.fullName  print "Fullname:", y.fullName
64  print "Module  :", y.klass.module.fullName  print "Module  :", y.klass.module.fullName
65    print "Type    :", y.gnue_type

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26