I have a little web application deployed on an ec2 instance and I\'d like to test it without making it publicly available.
Using an elastic IP does not solve my iss
Create a security group that only allows traffic from your IP (the IP of the machine running the browser where you will do the testing) to the web server port (80, probably) and assign this security group to your ec2 instance.
This way only you can access the web app.
If you need to work from different locations, write a simple script to update the security group and add your current IP. These changes are applied immediately and do not require a restart. You can grab your current IP from whatismyip and use the Amazon SDK to update the security group.