Skip to content
Accessibility Insights for Web
TypeScript CSS Other
Branch: master
Clone or download
dbjorge chore: fix alphabetization of run scripts in package.json (#2003)
#### Description of changes

Minor change, no functional impact; just cleans up formatting of package.json scripts

#### Pull request checklist
<!-- If a checklist item is not applicable to this change, write "n/a" in the checkbox -->
- [n/a] Addresses an existing issue: #0000
- [x] Ran `yarn fastpass`
- [n/a] Added/updated relevant unit test(s) (and ran `yarn test`)
- [n/a] Verified code coverage for the changes made. Check coverage report at: `<rootDir>/test-results/unit/coverage`
- [x] PR title *AND* final merge commit title both start with a semantic tag (`fix:`, `chore:`, `feat(feature-name):`, `refactor:`). Check workflow guide at: `<rootDir>/docs/workflow.md`
- [n/a] (UI changes only) Added screenshots/GIFs to description above
- [n/a] (UI changes only) Verified usability with NVDA/JAWS
Latest commit 4387a31 Jan 17, 2020
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.dependabot feat(office-fabric): update dependabot config (#1976) Jan 13, 2020
.github docs: improve issues template (#1765) Dec 1, 2019
.vscode chore: add vscode configuration for debugging the renderer process (#… Dec 11, 2019
deploy feat(release-channels): publish intermediate electron release channel… Jan 15, 2020
docs chore: add vscode configuration for debugging the renderer process (#… Dec 11, 2019
pipeline feat(release-channels): publish intermediate electron release channel… Jan 15, 2020
src feat(unified-channels): Add grunt machinery for per-channel unified p… Jan 18, 2020
.dockerignore .dockerignore test-results to avoid pushing stale results into test c… Jul 11, 2019
.gitattributes adding prettier (not enabling yet) (#100) Jan 22, 2019
.gitignore feat(report package) Implemented report npm package (#1741) Nov 27, 2019
.ignoredRevs chore: update git blame config file (#1957) Jan 9, 2020
.prettierignore feat(report package) Implemented report npm package (#1741) Nov 27, 2019
.yarnrc chore: manually update license-check-and-add to 3.0.3 (#1301) Sep 26, 2019
AppXManifest.xml feat: adjust drop folder directory structure to prepare for electron … Nov 6, 2019
CODE_OF_CONDUCT.md Adding Code of Conduct and Contributing MD files (#369) Mar 15, 2019
CONTRIBUTING.md Add guidance for git branch setup (#381) Mar 19, 2019
Dockerfile fix: minor changes to improve stability for e2e tests (#1722) Nov 21, 2019
Gruntfile.js feat(unified-channels): Add grunt machinery for per-channel unified p… Jan 18, 2020
LICENSE Updating License text (#133) Jan 28, 2019
README.md chore: upgrade node LTS version in our build pipelines to 12.13.0 fro… Nov 20, 2019
build.yaml refactor: move platform electron installers to separate build (#1607) Nov 1, 2019
copyright-header.config.json feat(report package) Implemented report npm package (#1741) Nov 27, 2019
copyright-header.txt Migrate code to GitHub Jan 4, 2019
electron-builder.yml fix: remove electron per-machine installer option & old data on unins… Jan 9, 2020
jest.config.js Add Spectron E2E tests for Electron (#1001) Aug 2, 2019
new-appx.ps1 feat: adjust drop folder directory structure to prepare for electron … Nov 6, 2019
package.json chore: fix alphabetization of run scripts in package.json (#2003) Jan 18, 2020
prettier.config.js chore: update line width for folder scr/common (partial update) (#1964) Jan 10, 2020
targets.config.js feat(unified-channels): Add grunt machinery for per-channel unified p… Jan 18, 2020
tsconfig.json chore: use alwaysStrict config in tsconfig to make sure we use TS in … Sep 3, 2019
tslint.json Retrieve Snippet from Element (#998) Aug 2, 2019
wallaby.conf.js Enable continuous testing by adding wallaby.js support (#290) Mar 6, 2019
webpack.config.js chore: Enable CSP script-src for electron product (#1864) Dec 17, 2019
yarn.lock chore(deps): bump office-ui-fabric-react from 7.82.2 to 7.83.1 (#1998) Jan 17, 2020

README.md

Product Logo Accessibility Insights for Web

Build Status Azure DevOps coverage Chrome Web Store Chrome Web Store Chrome Web Store Dependabot Status

Accessibility Insights for Web is a Google Chrome and Microsoft Edge Insider browser extension for assessing the accessibility of web sites and web applications.

Running the extension

You can install the extension from one of the following links

Building the code

Prerequisites

Please ensure that you have at least the minimum recommended versions

  • Node - 12.13.0 (Check by running node --version) - This is the version being enforced on our builds
  • Yarn - Version >= v1.17.3 (Check by running yarn --version)

In case you don't have yarn, please install from: Yarn

1. Fork and clone the repository

2. Install packages

  • Install the packages

    yarn install

3. Build and run unit tests

  • Build and run the unit tests
    yarn build
    yarn test
  • Run the end-to-end tests (note: you must use a non-admin prompt to avoid this issue)
    yarn test:e2e
    There are more details in the Testing section below.

4. Load the extension locally

  • Build the (unpacked) extension

    yarn build
  • Add the extension to your browser

    • Click on the 3-dotted-menu in the upper right corner and then select "More Tools" and then "Extensions"

    • Verify that developer mode is enabled in the upper right

    • Click on the Load unpacked button

    • Choose the following directory

      ./drop/extension/dev/product/ - bundled like a production release

    IMPORTANT: Ensure that you are testing locally before pushing a change.

  • Look for the Dev Logo extension icon to the right of the address bar

5. Commands to run before check in

  • You should run a FastPass (formatting and lint checks) before creating a Pull Request to master:

    yarn fastpass
  • If this catches formatting or linting issues, you can fix them with a combination of:

    yarn fastpass:fix
    
    # or, or individual steps:
    yarn lint:fix
    yarn format:fix
    yarn copyright:fix
  • We normally don't run the full end to end test suite before sending a Pull Request (we let the build agents do that), but if you are working on a change where you are particularly concerned about breaking end to end tests, you can run all of our Pull Request checks with:

    yarn assessment

More Information

Developer Workflow

Testing

We use jest as our test framework and puppeteer for browser automation in our end-to-end UI tests.

This project's end to end tests require the ability to run a non-headless chromium process. Because of this, they are incompatible with non-graphical development environments (notably, a default WSL environment on Windows). For an example of emulating a graphical environment using xvfb, see ./Dockerfile. For details, see issue #853.

Using VS Code

To run a task from the command palette, press Ctrl + Shift + P, select Tasks: Run Task, and select the task you want to run:

  • Test current file in VSCode runs just the tests in the currently-opened test file

To debug a test inside VS Code, set a breakpoint and click the debug button or press F5.

To attach VS Code as a debugger to a separate instance of Chrome, make sure you've launched Chrome with the --remote-debugging-port=9230 command line argument, and then use either of the Attach debugger... debug profiles from the VS Code Debug pane.

To debug using an external tool, run the Debug current test file outside VS Code task. In Chrome, for example, navigate to chrome://inspect and click Open dedicated DevTools for Node.

You can start an interactive watch session that automatically runs tests affected by uncommitted changes. To do this, run Begin Jest watch session from the command palette.

Using the terminal

yarn test runs all unit tests. yarn test -u runs all unit tests and updates snapshot files.

yarn test:e2e runs all end-to-end tests - you'll need to run yarn build first if you've changed non-test code. yarn test:e2e -u runs all end-to-end tests and updates snapshot files.

yarn test:e2e:docker runs all end-to-end tests in the same Docker container our linux CI build uses. Prerequisite: Install Docker.

Extra command line arguments and flags are passed along to Jest. For example:

  • To run a single or small number of unit test files, run yarn test -- -- {FILE_NAME_REGEX}
  • yarn watch:test will start an interactive watch session.

See more about Jest options here.

To debug using an external tool, run node --inspect-brk ./node_modules/jest/bin/jest.js --projects src/tests/unit --runInBand -- {RELATIVE_FILE_PATH}. In Chrome, for example, navigate to chrome://inspect and click Open dedicated DevTools for Node.

Data/Telemetry

By opting into telemetry, you help the community develop inclusive software. We collect anonymized data to identify the top accessibility issues found by the users. This will help focus the accessibility tools and standards community to improve guidelines, rules engines, and features.

This project collects usage data and sends it to Microsoft to help improve our products and services. Read our privacy statement to learn more.

Reporting security vulnerabilities

If you believe you have found a security vulnerability in this project, please follow these steps to report it. For more information on how vulnerabilities are disclosed, see Coordinated Vulnerability Disclosure.

FAQ

Please visit our FAQ page.

Contributing

All contributions are welcome! Please read through our guidelines on contributions to this project.

Code of Conduct

Please read through our Code of Conduct to this project.

You can’t perform that action at this time.