ReproNim / reproschema-py

Apache License 2.0
2 stars 8 forks source link

conversion tools #3

Open Remi-Gau opened 4 years ago

Remi-Gau commented 4 years ago

hey @satra

in case some of the ugly python code I have been creating to create the cobidas schema is useful, feel free to reuse it to recycle and improve.

it is here: https://github.com/Remi-Gau/COBIDAS_chckls/tree/master/conversion_scripts

satra commented 4 years ago

thanks @remi - this should be helpful for the python version. i spoke to @sanuann yesterday and she plans to update the javascript converter as that may still be useful in some javascript tabular ui.

Remi-Gau commented 4 years ago

I also think that having some "tools" in both languages might definitely help with adoption. :smile:

satra commented 4 years ago

@Remi-Gau - when you get a chance could you please send a PR adding your conversion script, so that we know you contributed it. i can then refactor it to do the conversion from google spreadsheets/redcap csv's.

Remi-Gau commented 3 years ago

@satra Quick question: what would be a sensible "testing" strategy for the code that should help with schema creation?

Would the idea be to have a sample of test.jsonld files that we check the output of the test against?

satra commented 3 years ago

Yes. Having a set of files/folders that can be produced by the generation code would be a set of tests.

To be comprehensive, we would want a set of crud (create, read, update, delete) tests

Remi-Gau commented 3 years ago

will have to get familiar with crud then because the only crud I knew till now was that of Paul Mheel

OK so apparently this is completely different from setup and teardown within a test, these are the different types of behavior we would like to create test for, is that correct?

satra commented 3 years ago

these are the different types of behavior we would like to create test for, is that correct?

yes, if you think of the reproschema-py as kind of an API and reproschema as a DB, then the library needs tests for its operations, which are referred to as CRUD. these would be separate tests, but they may have many variants as well. it is a good lens to think through about the use cases and tests.