How do you check the calculator?

How do you check the calculator? Any thoughts?

thank,

=== Sorry that I did not set out this question in great detail at the beginning. Now I want to talk more about this. This question was asked during a technical interview for a programmer . So I guess they were looking for some really smart answers or some good approach to testing such an application ...

Thanks again.

+3
source share
5 answers
  • Implement the interface. Does this do what you expect?
  • Manage functionality. Does this do what you expect?
  • . ? ? ?
+7

, ... .

+3

...

.

,

+2

, , , . , , .

, .

Finally, you will need to check all non-mathematical functionality - does the clear button clear the display? Are your cancel buttons canceled correctly? Etc.

+1
source

In general, you want to check for boundaries for each possible operation.

For example, to add, you check negative additions, additions containing irrational or infinite numbers, etc.

To divide, you must check the division by 0, etc.

0
source

Source: https://habr.com/ru/post/1754280/


All Articles