puppeteer-ruby 0.28.1 → 0.31.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +35 -1
- data/README.md +29 -9
- data/docs/api_coverage.md +359 -0
- data/lib/puppeteer.rb +8 -167
- data/lib/puppeteer/aria_query_handler.rb +71 -0
- data/lib/puppeteer/browser_runner.rb +1 -1
- data/lib/puppeteer/connection.rb +11 -1
- data/lib/puppeteer/custom_query_handler.rb +51 -0
- data/lib/puppeteer/dom_world.rb +372 -228
- data/lib/puppeteer/element_handle.rb +28 -33
- data/lib/puppeteer/env.rb +7 -3
- data/lib/puppeteer/execution_context.rb +12 -0
- data/lib/puppeteer/frame.rb +31 -24
- data/lib/puppeteer/launcher/base.rb +8 -0
- data/lib/puppeteer/page.rb +114 -105
- data/lib/puppeteer/puppeteer.rb +164 -0
- data/lib/puppeteer/query_handler_manager.rb +65 -0
- data/lib/puppeteer/remote_object.rb +12 -0
- data/lib/puppeteer/version.rb +2 -2
- data/lib/puppeteer/wait_task.rb +33 -26
- data/lib/puppeteer/web_socket.rb +2 -0
- data/lib/puppeteer/web_socket_transport.rb +2 -0
- data/puppeteer-ruby.gemspec +5 -2
- metadata +23 -11
- data/.circleci/config.yml +0 -92
- data/.github/ISSUE_TEMPLATE/bug_report.md +0 -17
- data/.github/stale.yml +0 -16
- data/.github/workflows/docs.yml +0 -45
- data/.github/workflows/reviewdog.yml +0 -15
- data/.gitignore +0 -19
- data/.travis.yml +0 -7
data/.circleci/config.yml
DELETED
@@ -1,92 +0,0 @@
|
|
1
|
-
version: 2.1
|
2
|
-
|
3
|
-
rspec_chrome_job: &rspec_chrome_job
|
4
|
-
steps:
|
5
|
-
- checkout
|
6
|
-
- run:
|
7
|
-
command: gem install bundler:2.2.3 && bundle install
|
8
|
-
- run:
|
9
|
-
name: rspec
|
10
|
-
command: |
|
11
|
-
DEBUG=1 bundle exec rspec --profile 10 \
|
12
|
-
--format RspecJunitFormatter \
|
13
|
-
--out test_results/rspec.xml \
|
14
|
-
--format documentation
|
15
|
-
|
16
|
-
jobs:
|
17
|
-
rspec_chrome_ruby2_6:
|
18
|
-
docker:
|
19
|
-
- image: circleci/ruby:2.6.6-buster-node-browsers
|
20
|
-
<<: *rspec_chrome_job
|
21
|
-
|
22
|
-
rspec_chrome_ruby2_7:
|
23
|
-
docker:
|
24
|
-
- image: circleci/ruby:2.7.2-buster-node-browsers
|
25
|
-
<<: *rspec_chrome_job
|
26
|
-
|
27
|
-
rspec_chrome_ruby3_0:
|
28
|
-
docker:
|
29
|
-
- image: circleci/ruby:3.0.0-rc1-buster-node-browsers
|
30
|
-
<<: *rspec_chrome_job
|
31
|
-
|
32
|
-
rspec_firefox:
|
33
|
-
docker:
|
34
|
-
- image: circleci/ruby:2.7.2-buster-node-browsers
|
35
|
-
steps:
|
36
|
-
- checkout
|
37
|
-
- run:
|
38
|
-
command: gem install bundler:2.2.3 && bundle install
|
39
|
-
- run:
|
40
|
-
name: install firefox-nightly
|
41
|
-
command: |
|
42
|
-
wget -O nightly.tar.bz2 "https://download.mozilla.org/?product=firefox-nightly-latest-ssl&os=linux64&lang=en-US"
|
43
|
-
tar xf nightly.tar.bz2
|
44
|
-
- run:
|
45
|
-
name: rspec
|
46
|
-
command: |
|
47
|
-
DEBUG=1 PUPPETEER_PRODUCT_RSPEC=firefox \
|
48
|
-
PUPPETEER_EXECUTABLE_PATH_RSPEC=${CIRCLE_WORKING_DIRECTORY/#\~/$HOME}/firefox/firefox \
|
49
|
-
bundle exec rspec --profile 10 \
|
50
|
-
--format RspecJunitFormatter \
|
51
|
-
--out test_results/rspec.xml \
|
52
|
-
--format documentation spec/integration/
|
53
|
-
|
54
|
-
deploy:
|
55
|
-
docker:
|
56
|
-
- image: circleci/ruby:2.6.3-stretch-node
|
57
|
-
steps:
|
58
|
-
- checkout
|
59
|
-
- run:
|
60
|
-
command: gem install bundler:2.2.3 && bundle install
|
61
|
-
- run:
|
62
|
-
name: rake build
|
63
|
-
command: rake build
|
64
|
-
- run:
|
65
|
-
name: setup API key
|
66
|
-
command: |
|
67
|
-
mkdir -p ~/.gem/
|
68
|
-
echo "---" > ~/.gem/credentials
|
69
|
-
echo ":rubygems_api_key: $RUBYGEMS_API_KEY" >> ~/.gem/credentials
|
70
|
-
chmod 600 ~/.gem/credentials
|
71
|
-
- run:
|
72
|
-
name: Check Puppeteer::version
|
73
|
-
command: bundle exec ruby -e 'raise "invalid Puppeteer::VERSION" unless Puppeteer::VERSION == ENV["CIRCLE_TAG"]'
|
74
|
-
- run:
|
75
|
-
name: gem push
|
76
|
-
command: gem push pkg/puppeteer-ruby-$CIRCLE_TAG.gem
|
77
|
-
|
78
|
-
workflows:
|
79
|
-
ci:
|
80
|
-
jobs:
|
81
|
-
- rspec_chrome_ruby2_6
|
82
|
-
- rspec_chrome_ruby2_7
|
83
|
-
- rspec_chrome_ruby3_0
|
84
|
-
- rspec_firefox
|
85
|
-
rubygems-deploy:
|
86
|
-
jobs:
|
87
|
-
- deploy:
|
88
|
-
filters:
|
89
|
-
tags:
|
90
|
-
only: /^[0-9]\.[0-9]+\.[0-9].*/
|
91
|
-
branches:
|
92
|
-
ignore: /.*/
|
@@ -1,17 +0,0 @@
|
|
1
|
-
---
|
2
|
-
name: Bug report
|
3
|
-
about: Create a report to help us improve
|
4
|
-
title: ''
|
5
|
-
labels: ''
|
6
|
-
assignees: ''
|
7
|
-
|
8
|
-
---
|
9
|
-
|
10
|
-
### Step To Reproduce / Observed behavior
|
11
|
-
|
12
|
-
|
13
|
-
### Expected behavior
|
14
|
-
|
15
|
-
### Environment
|
16
|
-
|
17
|
-
Paste the output of `ruby --version`
|
data/.github/stale.yml
DELETED
@@ -1,16 +0,0 @@
|
|
1
|
-
# Number of days of inactivity before an issue becomes stale
|
2
|
-
daysUntilStale: 14
|
3
|
-
# Number of days of inactivity before a stale issue is closed
|
4
|
-
daysUntilClose: 7
|
5
|
-
# Issues with these labels will never be considered stale
|
6
|
-
exemptLabels:
|
7
|
-
- security
|
8
|
-
# Label to use when marking an issue as stale
|
9
|
-
staleLabel: inactive
|
10
|
-
# Comment to post when marking an issue as stale. Set to `false` to disable
|
11
|
-
markComment: >
|
12
|
-
This issue has been automatically marked as stale because it has not had
|
13
|
-
recent activity. It will be closed if no further activity occurs. Thank you
|
14
|
-
for your contributions.
|
15
|
-
# Comment to post when closing a stale issue. Set to `false` to disable
|
16
|
-
closeComment: false
|
data/.github/workflows/docs.yml
DELETED
@@ -1,45 +0,0 @@
|
|
1
|
-
name: update docs
|
2
|
-
on:
|
3
|
-
push:
|
4
|
-
branches:
|
5
|
-
- master
|
6
|
-
|
7
|
-
jobs:
|
8
|
-
update-docs:
|
9
|
-
name: update docs
|
10
|
-
runs-on: ubuntu-latest
|
11
|
-
|
12
|
-
steps:
|
13
|
-
- name: Checkout
|
14
|
-
uses: actions/checkout@v2
|
15
|
-
|
16
|
-
- name: Set up Ruby
|
17
|
-
uses: ruby/setup-ruby@v1
|
18
|
-
with:
|
19
|
-
ruby-version: 2.7
|
20
|
-
|
21
|
-
- name: Install dependencies
|
22
|
-
run: |
|
23
|
-
gem uninstall bundler
|
24
|
-
gem install bundler -v 2.2.3
|
25
|
-
bundle install
|
26
|
-
|
27
|
-
- name: Deploy Configuration
|
28
|
-
run: |
|
29
|
-
mkdir ~/.ssh
|
30
|
-
ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
|
31
|
-
echo "${{ secrets.DOCS_DEPLOY_SSH_RSA }}" | base64 -d > ~/.ssh/id_rsa
|
32
|
-
chmod 400 ~/.ssh/id_rsa
|
33
|
-
|
34
|
-
- name: Build and Push
|
35
|
-
run: |
|
36
|
-
git clone git@github.com:YusukeIwaki/puppeteer-ruby-docs.git docs
|
37
|
-
rm -rf docs/*
|
38
|
-
bundle exec yardoc -o docs
|
39
|
-
cp puppeteer-ruby.png docs/
|
40
|
-
cd docs/
|
41
|
-
git add -A
|
42
|
-
git config user.name github
|
43
|
-
git config user.email github@example.com
|
44
|
-
git commit -m ${{ github.sha }}
|
45
|
-
git push origin master
|
@@ -1,15 +0,0 @@
|
|
1
|
-
name: reviewdog
|
2
|
-
on: [pull_request]
|
3
|
-
jobs:
|
4
|
-
rubocop:
|
5
|
-
name: runner / rubocop
|
6
|
-
runs-on: ubuntu-latest
|
7
|
-
steps:
|
8
|
-
- name: Check out code
|
9
|
-
uses: actions/checkout@v2
|
10
|
-
- name: rubocop
|
11
|
-
uses: reviewdog/action-rubocop@v1
|
12
|
-
with:
|
13
|
-
github_token: ${{ secrets.github_token }}
|
14
|
-
reporter: github-pr-review
|
15
|
-
rubocop_version: 1.8.0
|
data/.gitignore
DELETED