Capture with CasperJS does not render web fonts - capture

I'm using Glyphicons in my page. It works well in Chrome. But when I use the capture()method from CasperJS, I see "crosses" instead of icons.
I didn't find any hack to achieve that.
phantomjs --version
1.9.7
casperjs --version
1.1.0-beta3

Related

protractor appears to interrupt Node when run against Firefox

Background: I am running tests in the Protractor framework against a website written in Angular using Firefox as the browser
The website initially loads with a Server-side render. The follow-up client-side render appears to get interrupted. Angular is available, but nothing in the Dom loads.
Asking Google hasn't helped(none of the Stackoverflow results appeared to be relevant). Didn't see any open issues or closed issues on the Protractor github which appeared to be relevant
I'm not sure what's relevant to the investigation, so starting information:
Firefox version: 65
geckodriver version: v0.24.0 [last]
protractor version: 5.4.1
framework: jasmine
directconnect = true
Has anyone resolved this issue before? Is there additional information which would be relevant. What have I missed? The same tests running against Chrome pass without issue

CasperJS with Slimerjs - Xlib: extension "RANDR" missing on display ":99"

I am trying to running Casperjs with Slimerjs
I Installed SlimerJS 0.10.2
I have installed Mozilla Firefox 45.5.1 (tried with 50 too)
I have installed CasperJS 1.1.3
I have installed xvfb 1.17.4
Running on Centos 6.8
When tried to run a casperjs+slimerjs from php I get:
Gecko error: it seems /usr/bin/firefox is not compatible with SlimerJS.
See Gecko version compatibility. If version is correct, launch slimerjs
with --debug=true to see Firefox error message
When I try to run a script from console with debug=true like:
/usr/local/bin/casperjs /tmp/casperjs-5cn484 --debug=true --engine=slimerjs
(I tried with xvfb-run too)
I get this error:
Xlib: extension "RANDR" missing on display ":99".
process 5588: D-Bus library appears to be incorrectly set up; failed to read machine uuid: Failed to open "/var/lib/dbus/machine-id": No such file or directory
See the manual page for dbus-uuidgen to correct this issue.
D-Bus not built with -rdynamic so unable to print a backtrace
Redirecting call to abort() to mozalloc_abort
/usr/lib/node_modules/slimerjs/src/slimerjs: line 167: 5588 Segmentation fault "$SLIMERJSLAUNCHER" -app "$SLIMERDIR/application.ini" $PROFILE -no-remote "$#"
if i run slimerjs --debug=true, I get:
Error: cannot open display: :1.1
Gecko error: it seems /usr/bin/firefox is not compatible with SlimerJS.
See Gecko version compatibility. If version is correct, launch slimerjs
with --debug=true to see Firefox error message
I already tried a lot of solution, like:
tried: Xvfb :1 -screen 0 1024x768x24 +extension RANDR & and export DISPLAY=:1 (with :99 too)
tried export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/
upgrade downgrade firefox version
check if there was fonts, there is one, so no problem
I don't know what I am trying anymore, some suggestions? : )
Anyway I get it running installing dbus package and with the comand:
dbus-uuidgen > /var/lib/dbus/machine-id
The Xlib: extension "RANDR" missing on display ":99" isn't a big issue...
from:
http://www.torkwrench.com/2011/12/16/d-bus-library-appears-to-be-incorrectly-set-up-failed-to-read-machine-uuid-failed-to-open-varlibdbusmachine-id/
Did you see this issue? Apparently you should:
Change the max version in src/application.ini
MaxVersion=45.*
I'm not sure about the xrandr error but it seems unrelated. Could be a result of experimentation or a red herring.
There's also a DBUS error that could be causing the subsequent segmentation fault.
I suggest you try to check it step by step:
see that firefox is working
X forwarding might help here, it would bring up the remote firefox window locally
make sure that firefox is working headless
you could generate an xvfb screenshot
check with slimerjs
check with your PHP wrapper script

running Karma in grunt with IE launcher in Linux box

We're creating a Linux build box for an angular and node application, we have setup grunt to run unit tests against 3 browsers (IE, Chrome and FF).
Now that we're automating the build, we won't be able to run unit tests against IE.
I've read Karma docs and I've learned about PhantomJS, but from what I read it is build on webkit which is chrome.
Searching the internet gave me no answer to my questions:
1. Is PhantomJS sufficient to cover IE, chrome and FF? because it seems the only straight forward solution I got from Karma.
2. Is there any way I can run karma unit tests on IE in a Linux box? it seems like a common requirement but I'm surprised I found no answer.
I've installed GNOME on the build box to try to get at least Chrome and FF covered, but the problem was that if I run the grunt build from a terminal (ie. Putty) it won't launch Chrome or FF, I have to log in from the GUI to be able to launch the browsers through Karma.
I've also tried to install wine to install IE on the build box, but it installed only IE6!! :)
Our team is relatively new to NodeJs and Angular, how would you setup your build box and how would you cover unit tests in IE??
We ended up removing IE tests in Linux, but we run them in our windows dev boxes, and kept only Chrome and FF which are both working.

Node Webkit ember.js issue

i am trying to package a simple ember.js example with node webkit in mac-os 10.8 but i am getting the specified error "Running without renderer sandbox". Is there any issue with using ember.js with nodeWebkit b'coz when i am packaging without using ember.js it's working.
The warning message "Running without renderer sandbox" can be ignored. node-webkit doesn't have sandboxes as Chromium does.

Which gem is supposed to use to work with firefox using watir

I Tried with Installing gem Watir-WebDriver but it is not working. It's saying:
C:\Ruby187>gem install watir web-driver
Successfully installed watir-2.0.4
ERROR: Could not find a valid gem 'web-driver' (>= 0) in any repository
ERROR: Possible alternatives: megadriver, view_driver, testdrive, app_driver, web-facter
1 gem installed
Installing ri documentation for watir-2.0.4...
Installing RDoc documentation for watir-2.0.4...
Did you mean watir-webdriver? If that doesn't work, can you post the output of gem source?
Take a look at this page on how to install watir-webdriver gem: https://github.com/zeljkofilipin/watirbook/blob/master/installation/windows.md
You are telling the system to install two gems, one named 'watir', the other named 'web-driver'.
The watir gem exists, and is being installed. However, it is only for driving IE (firefox used to be supported via firewatir, but changes post 3.6 made it impossible to continue to support 'firewatir')
There is no gem named 'web-driver' which is what the error is telling you.
What you want to install is watir-webdriver. This is a version of watir that uses webdriver to drive the browsers, and offers cross browser support including latest versions of IE, Firefox, and Chrome..
See the link #Zeljko provided for detailed installation instructions for watir-webdriver.
use gem install watir-webdriver.

Resources