epiforecasts / covidregionaldata

An interface to subnational and national level COVID-19 data. For all countries supported, this includes a daily time-series of cases. Wherever available we also provide data on deaths, hospitalisations, and tests. National level data is also supported using a range of data sources as well as linelist data and links to intervention data sets.
https://epiforecasts.io/covidregionaldata/
Other
37 stars 18 forks source link

json loading tests #425

Closed RichardMN closed 2 years ago

RichardMN commented 2 years ago

This is currently a WIP to address #420.

seabbs commented 2 years ago

I think as written download_JSON will be called automatically from test_download which itself gets called automatically when DataClass$test() is called. That means I think that it will run the csv tests and hence maybe fail if the JSON isn't a table?

Not entirely sure what to do about this if we go with supporting non-datra frames as the output from download. I guess having a switch to only run tests if the output is a not JSON?

RichardMN commented 2 years ago

I've just stepped through the test_download (by running test(download = TRUE)) and it is running the same code as for a CSV. It doesn't fail but I don't see how to get it to run through JSON-specific tests either.

github-actions[bot] commented 2 years ago

This PR has been flagged as stale due to lack of activity