Package tests
[hide private]
[frames] | no frames]

Source Code for Package tests

 1  # This program is free software; you can redistribute it and/or modify 
 2  # it under the terms of the (LGPL) GNU Lesser General Public License as 
 3  # published by the Free Software Foundation; either version 3 of the  
 4  # License, or (at your option) any later version. 
 5  # 
 6  # This program is distributed in the hope that it will be useful, 
 7  # but WITHOUT ANY WARRANTY; without even the implied warranty of 
 8  # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
 9  # GNU Library Lesser General Public License for more details at 
10  # ( http://www.gnu.org/licenses/lgpl.html ). 
11  # 
12  # You should have received a copy of the GNU Lesser General Public License 
13  # along with this program; if not, write to the Free Software 
14  # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 
15  # written by: Jeff Ortel ( jortel@redhat.com ) 
16   
17  import sys 
18  import logging 
19   
20 -def setup_logging():
21 if sys.version_info < (2, 5): 22 fmt = '%(asctime)s [%(levelname)s] @%(filename)s:%(lineno)d\n%(message)s\n' 23 else: 24 fmt = '%(asctime)s [%(levelname)s] %(funcName)s() @%(filename)s:%(lineno)d\n%(message)s\n' 25 logging.basicConfig(level=logging.INFO, format=fmt)
26