Ignore:
Timestamp:
23 Mar 2012, 06:48:01 (13 years ago)
Author:
Henrik Bettermann
Message:

Disable external tests by default.

Reorganize tests slightly.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.custom/trunk/src/waeup/custom/etranzact/tests.py

    r7929 r7970  
    2020from waeup.custom.testing import FunctionalLayer
    2121
     22
     23# Also run tests that send requests to external servers?
     24#   If you enable this, please make sure the external services
     25#   do exist really and are not bothered by being spammed by a test programme.
     26EXTERNAL_TESTS = False
     27
     28def external_test(func):
     29    if not EXTERNAL_TESTS:
     30        myself = __file__
     31        if myself.endswith('.pyc'):
     32            myself = myself[:-2]
     33        print "WARNING: external tests are skipped!"
     34        print "WARNING: edit %s to enable them." % myself
     35        return
     36    return func
     37
    2238class EtranzactTests(StudentsFullSetup):
    2339    """Tests foreTranzact payment gateway.
     
    2844    CONFIRMATION_NO = '500856521315472785095'
    2945
     46    def test_dummy(self):
     47        return
     48
     49    @external_test
    3050    def test_etranzact_query_history(self):
    3151
Note: See TracChangeset for help on using the changeset viewer.