Well we may inspect the differences in other directions:
1. the involving subjects:
考试 is always talking about human beings, while
测试 can be used with human, but also animals, objects or even abstract things.
2. direction of the testing action:
no matter how it is used in a sentence, the ”testees" in 考试 must "actively" do something, eg:我们去考试,老师要考试我们,学校要举行考试,外语考试。
but the subjects in 测试, they can actively do something, but most case, they are "passively“ being examined, being probed, or being inspected,