コード例 #1
0
ファイル: test_tasks.py プロジェクト: yyinhai/browsercompat
 def test_call(self, mock_scrape):
     fp = FeaturePage.objects.create(
         feature_id=666,
         status=FeaturePage.STATUS_PARSING,
         url='https://developer.mozilla.org/en-US/_docs/hi')
     parse_page(fp.id)
     mock_scrape.assert_called_once_with(fp)
コード例 #2
0
 def test_call(self, mock_scrape):
     fp = FeaturePage.objects.create(feature_id=666, status=FeaturePage.STATUS_PARSING)
     parse_page(fp.id)
     mock_scrape.assertCalledOnce(fp.id)
コード例 #3
0
ファイル: test_tasks.py プロジェクト: renoirb/browsercompat
 def test_call(self, mock_scrape):
     fp = FeaturePage.objects.create(
         feature_id=666, status=FeaturePage.STATUS_PARSING,
         url="https://developer.mozilla.org/en-US/_docs/hi")
     parse_page(fp.id)
     mock_scrape.assert_called_once_with(fp)