Skip to content

Commit

Permalink
feat: add test.sh
Browse files Browse the repository at this point in the history
A simplistic test to test aria.js output.
Runs respec before and after copying aria.js changes.

NOTE: Assumes there's a copy of w3c/aria in ../aria/
  • Loading branch information
pkra committed Nov 27, 2023
1 parent 56a629e commit f52f2bf
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

# NOTE: Assumes there's a copy of w3c/aria in ../aria/

echo "Run respec on ../aria/index.html to generate 'before.html'"
npx respec --src ../aria/index.html --out before.html
echo "Copy ./script/aria.js to ../aria/common/script/"
cp ./script/aria.js ../aria/common/script/.
echo "Run respec on ../aria/index.html to generate 'after.html'"
npx respec --src ../aria/index.html --out after.html
echo "Run diff on 'before.html' and 'after.html'"
diff before.html after.html
echo "Clean up aria spec"
git -C ../aria/ checkout ./common/script/aria.js

0 comments on commit f52f2bf

Please sign in to comment.