-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[WIP] Add Github workflow to run NodeJS dump tree with Chromium
- Loading branch information
Showing
3 changed files
with
72 additions
and
34 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/sh | ||
|
||
export QT_ACCESSIBILITY=1 | ||
|
||
/usr/bin/chromium --force-renderer-accessibility --headless=new --disable-gpu "https://igalia.com" > /dev/null 2>&1 & | ||
|
||
pid=$! | ||
echo -n ${pid} > /tmp/chromium.pid | ||
|
||
sleep 3 | ||
|
||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Test NodeJS Dump Tree | ||
|
||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
launch_chromium: | ||
name: Dump tree against Chromium on Linux | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Install System dependencies | ||
run: sudo apt install -y at-spi2-core libatspi2.0-dev libnode-dev | ||
- name: Install node-gyp | ||
run: sudo npm install -g node-gyp | ||
- name: Install SWIG 4.1.0 | ||
run: | | ||
wget "https://github.com/swig/swig/archive/refs/tags/v4.1.0.tar.gz" | ||
tar -axf v4.1.0.tar.gz | ||
cd swig-4.1.0 | ||
./autogen.sh | ||
./configure --without-alllang --with-javascript --with-jsv8inc=/usr/include/v8 --with-jsv8lib=/usr/lib --with-python3 | ||
make -j | ||
sudo make install | ||
- uses: actions/checkout@v3 | ||
- name: Configure Project | ||
run: | | ||
mkdir -p build | ||
cd build | ||
cmake .. -DACACIA_NODEJS=on -DACACIA_PYTHON=off -DACACIA_TESTS=on | ||
- name: Build project | ||
run: | | ||
cd build | ||
make -j | ||
- name: Launch D-Bus Session bus service | ||
run: dbus-daemon --session & | ||
- name: Launch AT-SPI2 service | ||
run: | | ||
mkdir -p /run/user/1001/at-spi | ||
/usr/libexec/at-spi-bus-launcher & | ||
/usr/libexec/at-spi2-registryd --use-gnome-session & | ||
sleep 10 | ||
ps aux | grep at-spi | ||
- name: Install Chromium | ||
run: sudo apt install -y chromium-browser | ||
- name: Launch Chromium | ||
shell: bash | ||
run: | | ||
export QT_ACCESSIBILITY=1 | ||
export XDG_RUNTIME_DIR=/run/user/1001 | ||
export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1001/bus | ||
/usr/bin/chromium --force-renderer-accessibility --headless=new --disable-gpu "https://igalia.com" > /dev/null 2>&1 & | ||
sleep 10 | ||
- name: Run dump_tree_atspi examples | ||
shell: bash | ||
run: | | ||
cd build | ||
ps aux | grep chromium | ||
./examples/atspi/dump_tree_atspi --name chromium | ||
node ./examples/atspi/dump_tree_atspi.js --name chromium |