Example #1
0
 def test_bad_testplan(self):
     import aplt.runner as runner
     runner.run_testplan([
         "--log_output=none",
         "--websocket_url={}".format(AUTOPUSH_SERVER),
         "aplt.scenarios:basic, 5, 5",
     ], run=False)
 def test_class_method(self):
     import aplt.runner as runner
     lh = runner.run_testplan({
         "WEBSOCKET_URL": AUTOPUSH_SERVER,
         "TEST_PLAN": "aplt.tests:Aclass.amethod, 1, 1, 0",
     }, run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
 def test_wait_twice(self):
     import aplt.runner as runner
     lh = runner.run_testplan({
         "WEBSOCKET_URL": AUTOPUSH_SERVER,
         "TEST_PLAN": "aplt.tests:_wait_multiple, 1, 1, 0",
     }, run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
 def test_basic_testplan_with_args(self):
     import aplt.runner as runner
     lh = runner.run_testplan({
         "WEBSOCKET_URL": AUTOPUSH_SERVER,
         "TEST_PLAN": "aplt.scenarios:notification_forever, 5, 5, 0, 1, 1",
     }, run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
Example #5
0
 def test_class_method(self):
     import aplt.runner as runner
     lh = runner.run_testplan([
         "--log_output=none",
         "--websocket_url={}".format(AUTOPUSH_SERVER),
         "aplt.tests:Aclass.amethod, 1, 1, 0",
     ], run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
Example #6
0
 def test_basic_testplan_with_args(self):
     import aplt.runner as runner
     lh = runner.run_testplan([
         "--log_output=none",
         "--websocket_url={}".format(AUTOPUSH_SERVER),
         "aplt.scenarios:notification_forever, 5, 5, 0, 1, 1",
     ], run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
 def test_basic_testplan_with_vapid(self):
     import aplt.runner as runner
     lh = runner.run_testplan({
         "WEBSOCKET_URL": AUTOPUSH_SERVER,
         "TEST_PLAN":
             "aplt.scenarios:notification_forever, 5, 5, 0, 1, 1",
         "SCENARIO_KWARGS": {'vapid_claims': {
             "aud": "https://example.com",
             "sub": "mailto:[email protected]",
             "exp": int(time.time()) + 86400}},
     }, run=False)
     d = Deferred()
     reactor.callLater(0, self._check_testplan_done, lh, d)
     return d
 def test_bad_testplan(self):
     import aplt.runner as runner
     runner.run_testplan({
         "WEBSOCKET_URL": AUTOPUSH_SERVER,
         "TEST_PLAN": "aplt.scenarios:basic, 5, 5",
     }, run=False)