whole-tale / wt-design-docs

MIT License
5 stars 9 forks source link

v0.9rc1 testing (v0.9rc1-0-gb53b944 on OSX/Chrome) #125

Open bodom0015 opened 4 years ago

bodom0015 commented 4 years ago

Test Plan

https://github.com/whole-tale/wt-design-docs/issues/new?template=test_plan.md

Note: For all tests, repeat for supported browser/OS combinations.

Preconditions:

Authentication

NOTE: User's name/gravatar no longer displays in the navbar Filed https://github.com/whole-tale/dashboard/issues/590 since gravatar icon no longer displays in the navbar

Navigation

Browse

Preconditions:

Manage

Preconditions

NOTE: Zenodo missing from test confirmation

BUG: Registering "Humans and Hydrology" required a refresh afterward.. display was missing one or more datasets before refresh.

NOTE: Punctuation is stripped - could this potentially result in a collision?

Run

Preconditions:

NOTE: Duplicate test case (see "View Tale" above)

NOTE: "Move To..." is also here (and works), apparently

NOTE: "External Data" does not start empty for LIGO Tale

BUG: Copying a folder, then immediately removing it does not update the UI (hint: copy, navigate, navigate back, then remove does work properly)

Settings

BUG: Hard-coded dashboard.local (see https://github.com/whole-tale/dashboard/pull/589)

BUG: "Connect Account" not disabled after all servers registered

BUG: "Connect Account" not disabled after all servers registered

NOTE: I can't run this case, since I don't have SSH access to the staging VM, and therefore cannot use Docker exec.

Tale Creation

NOTE: Which Jupyter? Each?

NOTE: Error does not explicitly say that we have hit the max limit

Analyze in Whole Tale

Task 1: Importing a Dataset from Dataverse

These test cases cover potential situations that can occur when importing datasets from Dataverse.

Testing Steps:

  1. Remove all running Tale instances
  2. Navigate to https://girder.stage.wholetale.org/api/v1/integration/dataverse?datasetPid=doi%3A10.7910%2FDVN%2F3MJ7IR&siteUrl=https%3A%2F%2Fdataverse.harvard.edu
  3. Confirm that the Tale title reads as Replication Data for: "Agricultural Fires and Health at Birth"
  4. Confirm that the only item in the Input data section matches the uri with Data Source appended
  5. Confirm that no environment is selected
  6. Confirm that the Create New Tale and Launch button is disabled
  7. Select an environment
  8. Confirm that READ WRITE is selected
  9. Click Create New Tale and Launch
  10. Confirm that you are redirected to the run page
  11. Confirm that the Tale name matches the Tale Name in the Create Tale Modal
  12. Confirm that the data exists under External Data
  13. Confirm that the Tale's category is science

BUG: No "External Data" appeared, even after Tale was running. Dataset also did not appear under "Manage" after Tale was running

Task 2: Importing a Dataset from DataONE

These test cases cover different scenarios that may happen when importing datasets from DataONE.

This test covers the ideal case where dataset importing has all of the needed information to properly run. This includes the dataset location, title, and selected environment.

Testing Steps:

  1. Remove all running Tale instances
  2. Navigate to https://girder.stage.wholetale.org/api/v1/integration/dataone?uri=https%3A%2F%2Fsearch.dataone.org%2Fview%2Fdoi%3A10.18739%2FA2VQ2S94D&title=Fire%20influences%20on%20forest%20recovery%20and%20associated%20climate%20feedbacks%20in%20Siberian%20Larch%20Forests%2C%20Russia&environment=RStudio
  3. Confirm that the Tale title reads as Fire influences on forest recovery and associated climate feedbacks in Siberian Larch Forests, Russia
  4. Confirm that the only item in the Selected data section matches the uri with Data Source appended
  5. Confirm that Rstudio is selected in the Environments widget
  6. Confirm that the Create New Tale and Launch button is enabled
  7. Confirm READ ONLY is selected
  8. Click Create New Tale and Launch
  9. Confirm that you are redirected to the run page
  10. Confirm that the Tale name matches the Tale Name in the Create Tale Modal
  11. Confirm that the data exists in the Tale under External Data
  12. Confirm that the Tale's category is science

NOTE - Regarding this step:

Confirm that the only item in the Selected data section matches the uri with Data Source appended

I'm not sure what this actually means... confirm that the "DataSource"l isted matches the uri in the query string?

Links:

  1. https://dashboard.stage.wholetale.org/browse?api=https%3A%2F%2Fdev.nceas.ucsb.edu%2Fknb%2Fd1%2Fmn%2Fv2&name=Dataone Dataset&uri=https://dev.nceas.ucsb.edu/view/doi:10.5072/FK2K075M25
  2. https://dashboard.stage.wholetale.org/browse?api=https://test.arcticdata.io/metacat/d1/mn/v2&name=Dataone Dataset&uri=https://test.arcticdata.io/view/doi:10.5065/D6N014NC

Testing Steps:

  1. Remove all running Tale instances
  2. Navigate to each of the two links above
  3. Select an environment
  4. Click Create New Tale and Launch
  5. Confirm that the correct data exists in the Tale under External Data

NOTE: Accidental(?) dashboard.local above - should be dashboard.stage BUG(?): First dataset is just called proveit... is this correct? BUG(?): Second dataset is just called D6N014NC... is this correct?

Task 4: Shared Behavior

NOTE: There is no Task 3 in this list

These cases show errors that are common between Dataverse and DataONE. Although they are tested using DataONE URIs, the errors should be the same when replacing it with a Dataverse URI.

This test covers the case where the name query parameter is missing. The expected behavior is that the uri query parameter is used instead.

Testing Steps:

  1. Remove all running Tale instances
  2. Navigate to https://dashboard.stage.wholetale.org/browse?uri=https%3A%2F%2Fdataverse.harvard.edu%2Fapi%2Faccess%2Fdatafile%2F3323458
  3. Confirm that the Tale title reads as https://dataverse.harvard.edu/api/access/datafile/3323458
  4. Confirm that the only item in the Selected data section matches the uri with Data Source appended
  5. Confirm that no Environment is selected
  6. Confirm that the Create New Tale and Launch button is disabled
  7. Select an environment
  8. Click Create New Tale and Launch
  9. Confirm that the notification bar appears & properly updates
  10. Confirm that you are redirected to the run page
  11. Confirm that the Tale name matches the Tale Name in the Create Tale Modal
  12. Confirm that the data exists in the Tale under External Data

This test covers the case where a user imports data from an external source and selects READ/WRITE in the Create Tale Modal.

Testing Steps:

  1. Remove all running Tale instances
  2. Navigate to https://dashboard.stage.wholetale.org/browse?uri=https%3A%2F%2Fdataverse.harvard.edu%2Fapi%2Faccess%2Fdatafile%2F3323458 or https://dashboard.stage.wholetale.org/browse?api=https%3A%2F%2Fdev.nceas.ucsb.edu%2Fknb%2Fd1%2Fmn%2Fv2&environment=JupyterLab&name=proveit&uri=doi%3A10.5072%2FFK27P92Z55
  3. Confirm that the Tale title matches the dataset
  4. Confirm that the only item in the Selected data section matches the uri with Data Source appended
  5. Confirm that the Create New Tale and Launch button is disabled
  6. Select an environment
  7. Select READ/WRITE
  8. Click Create New Tale and Launch
  9. Confirm that the notification bar appears & properly updates
  10. Confirm that you are redirected to the run page
  11. Confirm that the Tale name matches the Tale Name in the Create Tale Modal
  12. Confirm that the data exists in the Tale Workspace

NOTE: is the Tale/Dataset title supposed to be proveit? Can't we just include that in the test case from now on? BUG: 404.html appeared under "External Data" BUG: No data ever appeared in the Tale Workspace

Tale metadata tests

The purpose of these tests are to confirm that the metadata files (manifest.json, environment.json, LICENSE) we generate are correct.

Publishing tests

NOTE: Which options are / are not dev servers? NOTE: Neither demo.dataverse.org nor dev2.dataverse.org appeared in the publishers list after connecting an API token

Zenodo integration tests

The register tests the following cases.

BUG: First register had _ver_2 suffix, not _ver_1 NOTE: For confirming contents, you can't browse into the Dataset from a Tale... easier to do this from the "Manage" page

The register tests the following cases.

  1. Open https://dashboard.stage.wholetale.org/browse?uri=https%3A%2F%2Fdoi.org%2F10.5281%2Fzenodo.3242073&environment=Jupyter%20Lab&name=Simple%20requirements.txt%20based%20example%20for%20repo2docker&asTale=true
  2. COnfirm Source Data and Title match URL and "READ WRITE" is selected
  3. Select 'Create and Launch Tale'
  4. Confirm image builds and notebook can run

NOTE: Jupyter%20Lab in querystring above should be JupyterLab

  1. Open https://girder.stage.wholetale.org/api/v1/integration/zenodo?doi=10.5281%2Fzenodo.2641313&resource_server=zenodo.org
  2. Confirm Water Tale is created.
  3. Confirm citation on Metadata view
  4. Confirm DOI matches above
  5. Use the Swagger UI to confirm the publishInfo field on the tale object contains pid, repository, repository_id, uri
  6. Run the tale and and notebook, confirm it works as expected (produces glorious map of Texas)

BUG - First step fails with a stack trace:

{
    "message": "AttributeError: AttributeError(\"'NoneType' object has no attribute 'get'\",)",
    "trace": [
        "<FrameSummary file /girder/girder/api/rest.py, line 630 in endpointDecorator>",
        "<FrameSummary file /girder/girder/api/rest.py, line 1210 in GET>",
        "<FrameSummary file /girder/girder/api/rest.py, line 967 in handleRoute>",
        "<FrameSummary file /girder/girder/api/describe.py, line 709 in wrapped>",
        "<FrameSummary file /girder/girder/api/rest.py, line 1280 in wrapped>",
        "<FrameSummary file /girder/plugins/wholetale/server/lib/zenodo/integration.py, line 57 in zenodoDataImport>",
        "<FrameSummary file /girder/plugins/wholetale/server/lib/zenodo/provider.py, line 108 in import_tale>",
        "<FrameSummary file /girder/plugins/wholetale/server/models/tale.py, line 383 in createTaleFromStream>"
    ],
    "type": "internal"
}

After rerunning with https://sandbox.zenodo.org/record/490450#.XjnHHRNKh25:

NOTE: Is there a specific way to "Import a Zenodo Tale"? Tried https://girder.stage.wholetale.org/api/v1/integration/zenodo?doi=10.5072%2Fzenodo.490330&resource_server=sandbox.zenodo.org, but will this actually resolve the DOI? This just redirected me to Browse... NOTE: What does "Download and run local" entail - is there a set of commands for this already?

Regression tests

NOTE: This could be merged with "View Tale" test case (see above) NOTE: Step 2 should be removed, as it does not make sense NOTE: Step 3 should say "View" instead of "Launch" - launching requires write access

bodom0015 commented 4 years ago

After rerunning "Zenodo Tale via AiWT" with @craig-willis' new DOI (https://sandbox.zenodo.org/record/490450#.XjnHHRNKh25):

BUG - modal never shows, AiWT never happens, and I am just redirected to Craig's existing Tale: https://dashboard.stage.wholetale.org/run/5e39d26e8bec16c2663dda16?token=wZrmafFvLyvyeGyKeP8ymzAVcoquvOObLqwwMLjfC6A7SonsvfomfbOE44KqAk2Q

Xarthisius commented 4 years ago

@bodom0015 it's not Craig's Tale, it's your copy. There's no modal, cause there's nothing for you to choose. You just described a feature not a bug :)

bodom0015 commented 4 years ago

Ah... you are correct! Well, that is genuinely confusing. :D

Unfortunately, the test case still fails because there is no citation or external data attached to the resulting Water Tale.

Results

Proposed improvements: https://github.com/whole-tale/wt-design-docs/pull/126

Failing Test Cases

Open Questions