advisory_testing.py 900 B

1234567891011121314151617181920212223242526272829
  1. ##############################################################################
  2. #
  3. # Copyright (c) 2003 Zope Foundation and Contributors.
  4. # All Rights Reserved.
  5. #
  6. # This software is subject to the provisions of the Zope Public License,
  7. # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
  8. # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
  9. # WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  10. # WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
  11. # FOR A PARTICULAR PURPOSE.
  12. #
  13. ##############################################################################
  14. import sys
  15. from zope.interface.advice import getFrameInfo
  16. my_globals = globals()
  17. ClassicClass = None
  18. class NewStyleClass:
  19. __metaclass__ = type
  20. classLevelFrameInfo = getFrameInfo(sys._getframe())
  21. moduleLevelFrameInfo = getFrameInfo(sys._getframe())