1

I just setup Robot Framework yesterday. I went to youtube to see some videos on how to set up and I found one that was just uploaded last month. I follow all the steps and I numbered it below.

  1. Installed Python 2.27 and added it on Environmental Variables
  2. Installed RobotFramework (3.0.2) using pip install robotframework (cmd run as Administrator)
  3. Installed Selenium 2 Library using pip install robotframework-selenium2library
  4. Downloaded the browser drivers (chromeDriver, GeckoDriver and IE Driver) and added on Environmental Variables
  5. Dowloaded the Robotframework Database-Libary ZIP here -> http://franz-see.github.io/Robotframework-Database-Library/, then extracted the downloaded zip file
  6. In cmd, I then key in python setup.py install (SUCCESS)
  7. Next, I installed the database APIs through pip install py mssql (SUCCESS)
  8. NOW, I downloaded PyCharm Community 2016.3 Installed IntelliBot plugin on PyCharm

I have created a project FirstProject. Under it I created a directory testsuite. In testsuite, I created my testcase1.robot and copy pasted some sample robot framework test on the editor and run it using command pybot testcase1.robot

However, I encountered an error saying [ERROR] Parsing 'testcase1.robot' failed: Data source does not exist.

Here's my code. It'll simply open facebook website through Chrome browser

========================================================================

*** Settings ***

Documentation This is my first robot framework test script

Library Selenium2Library

*** Variables ***

*** Test Cases ***

open browser  http://www.facebook.com  chrome

close browser

*** Keywords ***

======================================================================= Regardless of my code, did I miss something on my configuration? If not, what's wrong with the code? If fixed, will that make my test run? Any feedback is well appreciated. Thank you!

  • I have the exact same issue but On my Mac. – QATd3 Mar 11 '17 at 19:37
  • Presuming the whitespace in the original source is ok (is mangled here in SO), the error must probably comes from the way you try to start the particular case. Can you share the command you use to execute it. – Todor Minakov Mar 16 '17 at 7:02
2

"data source does not exist" simply means that you gave a filename to robot, and robot can't find that file.

For example:

$ pybot /path/to/non-existent/file
[ ERROR ] Parsing '/path/to/non-existent/file' failed: Data source does not exist.

That means that either:

  1. the file truly does not exist. For example, maybe you forgot to save the file
  2. you misspelled the filename
  3. you spelled the filename correct, the file exists, but it is in a different directory than the current working directory.

The first thing to do is to verify if the file exists. For example, you could type ls testcase1.robot and see if it shows up. If ls can't find the file, neither can robot.

The other thing to do is to cd to the folder that contains the test. That should solve the problem.

The final solution is to simply give the full path to the test.

0

This happens when you run the robot or pybot command from folder other than the one which contains your .robot tedt suite.

Navigate to the folder which contains the test suite and then run the pybot/ robot command.

You can also download RIDE - pip install robotframework-ride - It is the best IDE for robot framework if you are using windows machine.

  • 1
    I would argue that RIDE is the absolute worst IDE for robot. Pycharm is considerably better, as is RED (based on eclipse), brackets (brackets.io), and many others. – Bryan Oakley Mar 24 '17 at 16:32
  • With it's specific and brittle configuration RIDE is truly no longer the editor of choice on any platform, including windows. The others out there mentioned by @BryanOakley provide more functionality or a more complete development experience. – A. Kootstra Mar 27 '17 at 5:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.