Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

test_config.py 835 B

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
  1. from app import form_response
  2. class NotANumber(Exception):
  3. def __init__(self, message="Values entered are not Numerical"):
  4. self.message = message
  5. super().__init__(self.message)
  6. input_data = {
  7. "incorrect_values":
  8. {"number_vmail_messages": 3,
  9. "total_day_calls": 4,
  10. "total_eve_minutes": 'as',
  11. "total_eve_charge": 12,
  12. "total_intl_minutes": 1,
  13. "number_customer_service_calls": 'ab',
  14. },
  15. "correct_values":
  16. {"number_vmail_messages": 3,
  17. "total_day_calls": 4,
  18. "total_eve_minutes": 2,
  19. "total_eve_charge": 12,
  20. "total_intl_minutes": 1,
  21. "number_customer_service_calls": 4,
  22. }
  23. }
  24. def test_form_response_incorrect_values(data=input_data["incorrect_values"]):
  25. #res=form_response(data)
  26. #assert res == NotANumber().message
  27. assert True
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...