Because of the way the test is structured, you fail the test because your logic which determines the final value for message, is not contained within the “get” request callback function. Move it inside and you will pass the test.
Technically, your code works, but just not with the tests. In general though, this is a good reason to not create global variables. It is always better to declare variables within functions so as not to pollute the global scope.