facebookarchive / huxley

A testing system for catching visual regressions in Web applications.
Apache License 2.0
4.07k stars 286 forks source link

getting error during playback on Mac. #72

Open gunesmes opened 10 years ago

gunesmes commented 10 years ago

I am getting this error during the playback. I successfully recorded a case and taking 3 picture by huxley --record then quit and trying to check on firefox as following:

~/P/h/examples (master ⚡=) huxley --record
-------------------------------
Running Huxley file: Huxleyfile
-------------------------------
[toggle] Running test: toggle
Begin record
Press enter to take a screenshot, or type Q+enter if you're done

1 screenshots taken
Press enter to take a screenshot, or type Q+enter if you're done

2 screenshots taken
Press enter to take a screenshot, or type Q+enter if you're done

3 screenshots taken
Press enter to take a screenshot, or type Q+enter if you're done
q

Up next, we'll re-run your actions to generate screenshots to ensure they are pixel-perfect when running automated. Press enter to start.

Begin rerecord
  Sleeping for 5281.0 ms
  Taking screenshot 0
  Sleeping for 9555.0 ms
  Clicking [236, 153]
  Sleeping for 5554.0 ms
  Taking screenshot 1
  Sleeping for 11236.0 ms
  Clicking [326, 363]
  Sleeping for 6201.0 ms
  Taking screenshot 2

Playing back to ensure the test is correct

Begin playback
  Sleeping for 5281.0 ms
  Taking screenshot 0
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 808, in __bootstrap_inner
    self.run()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 761, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/Library/Python/2.7/site-packages/huxley/threadpool.py", line 32, in thread
    func(*args, **kwargs)
  File "/Library/Python/2.7/site-packages/huxley/cmdline.py", line 69, in run_test
    screensize=screensize
  File "/Library/Python/2.7/site-packages/huxley/main.py", line 110, in main
    TestRun.record(local_d, d, (url, postdata), screensize, filename, diffcolor, sleepfactor, save_diff)
  File "/Library/Python/2.7/site-packages/huxley/run.py", line 152, in record
    cls.rerecord(test, path, url, remote_d, sleepfactor, diffcolor, save_diff)
  File "/Library/Python/2.7/site-packages/huxley/run.py", line 79, in rerecord
    cls.playback(test, path, url, d, sleepfactor, diffcolor, save_diff)
  File "/Library/Python/2.7/site-packages/huxley/run.py", line 85, in playback
    run._playback(sleepfactor)
  File "/Library/Python/2.7/site-packages/huxley/run.py", line 95, in _playback
    step.execute(self)
  File "/Library/Python/2.7/site-packages/huxley/steps.py", line 103, in execute
    raise TestError('Screenshot %s was different.' % self.index)
TestError: Screenshot 0 was different.