コード例 #1
0
ファイル: tests.py プロジェクト: strogo/Frozen-Flask
 def make_app(self):
     with temp_directory() as temp:
         app, freezer = test_app.create_app(self.defer_init_app, self.freezer_kwargs)
         app.config["FREEZER_DESTINATION"] = temp
         app.debug = True
         self.do_extra_config(app, freezer)
         yield temp, app, freezer
コード例 #2
0
 def make_app(self):
     with temp_directory() as temp:
         app, freezer = test_app.create_app(self.defer_init_app,
                                            self.freezer_kwargs)
         app.config['FREEZER_DESTINATION'] = temp
         app.debug = True
         self.do_extra_config(app, freezer)
         yield temp, app, freezer
コード例 #3
0
ファイル: tests.py プロジェクト: strogo/Frozen-Flask
 def test_all_urls_method(self):
     app, freezer = test_app.create_app(freezer_kwargs=self.freezer_kwargs)
     expected = sorted(self.expected_output)
     # url_for() calls are not logged when just calling .all_urls()
     for url in self.generated_by_url_for:
         if url in expected:
             expected.remove(url)
     # Do not use set() here: also test that URLs are not duplicated.
     self.assertEquals(sorted(freezer.all_urls()), expected)
コード例 #4
0
 def test_all_urls_method(self):
     app, freezer = test_app.create_app(freezer_kwargs=self.freezer_kwargs)
     expected = sorted(self.expected_output)
     # url_for() calls are not logged when just calling .all_urls()
     for url in self.generated_by_url_for:
         if url in expected:
             expected.remove(url)
     # Do not use set() here: also test that URLs are not duplicated.
     self.assertEquals(sorted(freezer.all_urls()), expected)