11. PhantomJS
“PhantomJS is a headless WebKit with
JavaScript API. It has fast and native
support for various web standards:
DOM handling, CSS selector, JSON,
Canvas, and SVG.”
— http://phantomjs.org/
12. PhantomJS
“PhantomJS is a headless WebKit with
JavaScript API. It has fast and native
support for various web standards:
DOM handling, CSS selector, JSON,
Canvas, and SVG.”
— http://phantomjs.org/
15. JavaScript API
var page = require('webpage').create();
var url = 'http://www.phantomjs.org/';
page.open(url, function (status) {
//Page is loaded!
phantom.exit();
});
? PhantomJS の JS API でブラウジング
- new WebPage()?
? Web ページとは別のコンテキストで実行
22. “奥颈驳丑迟”
"Wight is a Middle English word, from
Old English wiht, and used to describe a
creature or living sentient being. It is
akin to Old High German wiht, meaning
a creature or thing."
36. Test::Wight
my $w = Test::Wight->new;
my $port = $w->spawn_psgi($app);
$w->visit('/');
is $w->evaluate('document.title'), 'title';
my $link = $wight->find('//p/a')
$link->click;
is $w->current_url->path, '/foo';