Domanda

I have some Selenium RC tests (written in PHP) testing an application in a sandbox where users need to type in their physical addresses. Addresses have to be real, otherwise application displays an error message. I'd like the scripts to input a new real US address every time the test runs. Any ideas how to implement this? Thanks!

È stato utile?

Soluzione

  1. Get a batch of fake names and addresses at: Fake Name Generator.

  2. Process the list through a CASS-Certified service such as LiveAddress for Lists. This will identify all the real and valid US addresses that happened to be generated.

  3. Extract only the valid addresses (see the simple-mailable file that comes with the download) for your testing purposes.

If you generate a few thousand random addresses on that website, you should get plenty of valid ones to test with, purely by chance.

I do work at SmartyStreets, and this is how we get "fake" data for showcasing our service or for help and instructional purposes (without exposing actual private information).

Altri suggerimenti

you can do that using the following steps: 1- select a random place from google-maps (choose it wisely, you don't want to choose a place too close to the water ).

2- get the latitude and longitude of that location.

3- generate random numbers( small ones, very small ones, both positive and negative) and add them to the selected latitude and longitude.

4- using google-maps api, you can retrieve addresses close to that position.

5- repeat for every random latitude and longitude -- and now you have automated the task.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top