Tell us what’s happening:
Describe your issue in detail here.
Can’t seem to pass the last test of the URL Shortner Microservice project.
Although its doing everything its supposed to do!
I am using validUrl library to check the urls. validUrl.isWebUri()
My first question would be: Does your response match the requested response? And important part of dev work is paying attention to small details. Computers aren’t really got at, “Well, that’s close enough, I think he know what he was thinking.”
Thanks a lot for the idea of using dev tools. The whole thing was already working fine as i had already tested. Turns out the test expected a status code of 200 while i was returning 401 while dealing with the invalid url. Such a pain, but atleast i now know 10 ways to test a url
I guess that too. I was trying to point out that the casing on the response does not match what is expected. Perhaps the test allows for that, but in general, bugs like that can cause nightmares. I saw a commercial app in production fail for that something similar - and the unit tests weren’t written well enough to catch it. You have to pay very close attention to things like that.