Skip to content

Improve testing #13

@ceckoslab

Description

@ceckoslab

Today our testing is basically comparing 2 JSON files.

Example:

    const expected = JSON.parse(fs.readFileSync(`./testdata/dashboards/${dashboard}.json`, { encoding: 'utf8', flag: 'r' }));
    const actual = JSON.parse(fs.readFileSync(`./build/dashboards/${dashboard}.json`, { encoding: 'utf8', flag: 'r' }));
    expect(actual).toMatchObject(expected);

Where this is convenient for an MVP it will be great if we actually start testing with code if a given panel has the expected configuration.

Let's write some testing code only for the General dashboard in this ticket.

Metadata

Metadata

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