I've been building up a Web app and want to test it in my iPhone in order to check that the responsive functionality works properly in mobile devices. When I develop it on my MacBook Pro, which connects to the Internet through Wi-Fi, I can access to localhost from iPhone by typing in the IP address to the address bar in Safari in iPhone.
However, my Desktop connects to the Internet using Thunderbolt Ethernet cable, and while it can connect with Wi-Fi by manually setting the Ethernet off, I still don't like to bother to disconnecting it just to check how my Web app works in mobile screen, and instead want to test it as readily as it is with Wi-Fi and typing in the address bar, like I said in my MacBook Pro case.
So is it feasible to connect to localhost from iPhone with Ethernet being used instead of Wi-Fi? I don't mind it if it's not "typing in address bar in Safari" or something like that, if there are other ways to resolve the issue here.
I use Mavericks 10.9.2 and iPhone 5 with iOS 7.1.1. I connect to localhost with node.js as backend, through port 3000.