Skip to content

Feature request: add ability to mock different api datasets #1

@mrshll1001

Description

@mrshll1001

It'd be good if users could mock different api datasets without having to remove their existing files. This could be used to mock an API with totally valid data, an API with totally broken data, and an API with mixed data etc etc.

This could be accompished by adding another layer of directories under data where each directory is named for an api dataset (a good word would be "profile", but we don't want to risk confusion with HSDS Profiles).

At the moment, the directory structure is as such:

data/
    services/
        example.json
    organizations/
        example.json
…

We could change it so that it is structured like this:

data/
    all-valid-data/
        services/
	    example.json
        organizations/
	    example.json
	…
    all-broken-data/
        services/
	    example.json
        organizations/
	    example.json
	…

And so forth.

Ideally, it'd be possible to pass an option to app.py which declared the name of the dataset directory to use. This way, a user can mock different API contents to test their program.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions