problem-specifications
problem-specifications copied to clipboard
complex-numbers: move exercise involving multiplication
Should we move the test for the imaginary unit to the "multiply" group of unit tests? I think it's currently too soon in the test suite.
There is a nice progression to the unit tests:
- real part
- imaginary part
- add
- subtract
- multiply
and so on. The test for the "imaginary unit" involves multiplication but is inserted between the "imaginary" and "add" groups.
I think this is purely historical. PR #718 created the tests, #1140 reordered them but missed this one.
I don't mind opening a PR but first I'd like to learn how to test changes.
In #718 I put it as the first test case because, at least informally, complex numbers are often defined or thought of as a + bi where i² = -1. The other properties can all be derived from that.
Edit: This is also the definition the exercise description uses.
I don't really care about the position in the canonical-data but that was the intention behind it.
@SaschaMann Ah, interesting! I didn't consider that point of view. I was trying to think of what the students would need to do to make the tests pass.
Maybe some mentors have feedback to give?
No comment has been made on this PR in the last 3 years. @KevinWMatthews are you still interested in pursuing this issue?