Troy Thompson

Web Developer

  1. Data Entry made Simple

    Published
    Last Updated
    Nov 29 2007
    Tagged
    Content

    As a web developer I often have to import data into web applications with no import feature.

    With a little programming knowledge you can import data without any knowledge of what is going on behind the scenes of a web application.

    Sometimes a web application adds generated data to a record making it difficult to import directly via MySQL or you lack the access needed to do so. In situations like this I prefer to use Selenium IDE ( screencast ).

    Selenium IDE allows you to record your actions via a Firefox extension and then save them for later playback. This is used mostly for automated acceptance testing, but for the purposes of this post we'll stick to data entry automation.

    You must record your actions to create a record in your target web application, then save the "test " out as a .html file. Now with your data, duplicating the necessary Selenise commands to create the records in your target web application.

    Any scripting language would do, if you know ruby, I'd recommend using the FasterCSV gem it handles .csv's very well.

    When you have created the test run it and watch a few entries go in to make sure nothing funky is happening.

    If you feel comfortable with how the data is going in go grab yourself a cup of coffee. Plus it is cool to make your co-workers think your computer has a mind of its own.

    1 Comment
    1. you can also use selenium to test a rails application as described here: http://www.slideshare.net/alexchaffee/fullstack-webapp-testing-with-selenium-and-rails

      Selenium is amazingly powerful and really fun.

    Respond
    ( will not be published or shared )