Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected repository content when populating database during setup #344

Closed
jkva opened this issue Oct 28, 2021 · 4 comments
Closed

Unexpected repository content when populating database during setup #344

jkva opened this issue Oct 28, 2021 · 4 comments

Comments

@jkva
Copy link
Contributor

jkva commented Oct 28, 2021

Hello,

While following the steps in database.md, I am trying to execute yarn db-import-tests:dev.

The cloning of the test repository succeeds, yet the build/tests/support.json file does not seem to contain the expected examples entry.

Is there something I am overlooking? The cloned file contents do match the current version of support.json in master.

aria-at-app HEAD commit: 3f8b636aad069ff81b70a6690f3e3e01d1b15e16.
Node: v4.18.1.

Dumped contents of support.json during command execution:

{
  ats: [
    { name: 'JAWS', key: 'jaws' },
    { name: 'NVDA', key: 'nvda' },
    { name: 'VoiceOver for macOS', key: 'voiceover_macos' }
  ],
  applies_to: {
    'Desktop Screen Readers': [ 'VoiceOver for macOS', 'NVDA', 'JAWS' ],
    'Screen Readers': [ 'VoiceOver for macOS', 'NVDA', 'JAWS' ]
  }
}

Command output:

➜  aria-at-app git:(develop) ✗ yarn db-import-tests:dev
yarn run v1.22.17
$ yarn workspace server db-import-tests:dev
$ DOTENV_CONFIG_PATH=../config/dev.env node -r dotenv/config ./scripts/import-tests/index.js
Cloned aria-at.git to /Users/job/clients/pac/aria-at-app/server/scripts/import-tests/tmp/
Error found: TypeError: support.examples is not iterable
    at Object.getMostRecentTests (/Users/job/clients/pac/aria-at-app/server/scripts/import-tests/index.js:100:37)
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed.
Exit code: 1
Command: /Users/job/.nvm/versions/node/v14.18.1/bin/node
Arguments: /usr/local/Cellar/yarn/1.22.17/libexec/lib/cli.js db-import-tests:dev
Directory: /Users/job/clients/pac/aria-at-app/server
Output:

info Visit https://yarnpkg.com/en/docs/cli/workspace for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
➜  aria-at-app git:(develop) ✗   
@jkva
Copy link
Contributor Author

jkva commented Oct 28, 2021

It looks like the examples entry was removed in https://github.com/w3c/aria-at/blob/c2df595d0581cf832122456ad3b6944d3152d225/build/tests/support.json.

in https://github.com/w3c/aria-at/blob/7131d5c8b096832484a6f4d7020bebe1f22ac13a/build/tests/support.json, support.json still contained

"examples": [
    {
      "directory": "checkbox",
      "name": "Checkbox Example (Two State)"
    },
    {
      "directory": "menubar-editor",
      "name": "Editor Menubar Example"
    }
  ]

@jkva
Copy link
Contributor Author

jkva commented Oct 28, 2021

It seems import-tests/index.js could be modified to parse discoveredreferences.csv files while iterating through ./tests/**/.

@howard-e
Copy link
Contributor

➜ aria-at-app git:(develop) ✗ yarn db-import-tests:dev

Hi @jkva. Currently, develop isn't stable. Due to changes in https://github.com/w3c/aria-at and a desire to completely drop support for the support.json in the future, the first change had started with dropping support for examples: [ ... ], and defining titles for the test plans within the relevant references.csv files.

See related issue & PRs:

  1. Replace support.json with key in references.csv aria-at#471
  2. Import tests TestPlanVersion title update #320
  3. Move test plan titles for app from support.json to references.csv aria-at#473
  4. Add title reference field to each test plan aria-at#521

There is an open PR (#342) intended to move all these changes to develop from reporting-integration. Until then, I would advise attempting to run the reporting-integration branch instead as that is the most stable at this time.

@jkva
Copy link
Contributor Author

jkva commented Oct 28, 2021

@howard-e ah, understood. I'll switch branches. Thanks for the response!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants