Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A443570919790955 tenders tests #11

Open
wants to merge 1 commit into
base: tests
Choose a base branch
from

Conversation

vladkhard
Copy link

No description provided.

@coveralls
Copy link

Coverage Status

Coverage increased (+19.5%) to 59.006% when pulling 9d95eaf on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from 9d95eaf to 3febc4b Compare October 5, 2017 13:37
@coveralls
Copy link

Coverage Status

Coverage increased (+20.5%) to 60.031% when pulling 3febc4b on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

call('Backward data sync finished.')
]

def raiser():
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mock допускає MagicMock(return_value=Exeception() або MagicMock(side_effect=[Exception()])
не потрібно загортати у функцію

call('Start backward data sync worker...')
]

self.assertEqual(mocked_logger.warn.mock_calls[0],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Для цього є метод assert_called_once_with

self.assertEqual(mocked_logger.warn.mock_calls[0],
call('Backward worker died!',
extra=journal_context({"MESSAGE_ID": DATABRIDGE_WORKER_DIED}, {})))
self.assertEqual(mocked_logger.exception.mock_calls[0], call(e))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Аналогічно

@coveralls
Copy link

Coverage Status

Coverage increased (+20.5%) to 60.061% when pulling 88eeb39 on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

]

cb.get_tenders = MagicMock(side_effect=[Exception()])
try:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

with self.assertRaises(Exception) as e:
    cb.get_tender_contracts_backward()

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from 88eeb39 to af3b3e7 Compare October 6, 2017 09:32
@coveralls
Copy link

Coverage Status

Coverage increased (+20.1%) to 59.692% when pulling af3b3e7 on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from af3b3e7 to 9ce15b6 Compare October 6, 2017 09:32
@coveralls
Copy link

Coverage Status

Coverage increased (+20.1%) to 59.692% when pulling 9ce15b6 on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from 9ce15b6 to ae29045 Compare October 6, 2017 09:35
@coveralls
Copy link

Coverage Status

Coverage increased (+19.9%) to 59.476% when pulling ae29045 on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from ae29045 to 2a10434 Compare October 6, 2017 11:54
@coveralls
Copy link

Coverage Status

Coverage increased (+19.8%) to 59.351% when pulling 2a10434 on vladkhard:a443570919790955_tenders_tests into f1138c9 on openprocurement:tests.

@VDigitall
Copy link
Member

get_tenders неправильно тестується

@vladkhard
Copy link
Author

тобто?

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch 2 times, most recently from 1f86250 to 2a4b77e Compare October 10, 2017 12:05
@coveralls
Copy link

Coverage Status

Coverage increased (+7.6%) to 84.298% when pulling 2a4b77e on vladkhard:a443570919790955_tenders_tests into 8bcba89 on openprocurement:tests.

@vladkhard vladkhard force-pushed the a443570919790955_tenders_tests branch from 2a4b77e to 0eb634d Compare November 20, 2017 10:01
@coveralls
Copy link

Coverage Status

Coverage increased (+11.5%) to 86.744% when pulling 0eb634d on vladkhard:a443570919790955_tenders_tests into e0ae513 on openprocurement:tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants