canonical / charmed-kubeflow-chisme

Shared Utilities used across Charmed Kubeflow
Apache License 2.0
1 stars 4 forks source link

Add helper function to test grafana-dashboard relation #101

Closed rgildein closed 3 weeks ago

rgildein commented 1 month ago

Context

In #97 we implemented cos integration abstraction to test relations with cos, however this issues was missing tests for grafana-dashboard relation.

This should include these two functions:

def assert_grafana_dashboards():
    """
    1. Get relation data.
    2. Get charm's grafana dashboards using get_grafana_dashboards_from_charm().
    3. Assert that returned data contain every grafana dashboard's name.
    """

def get_grafana_dashboards_from_charm()-> dashboards array:
    """
    1. Get grafana dashboards from `src/grafana_dashboards` directory
    2. Return an array with their names.
    """

What needs to get done

  1. Add functions defined above.
  2. Add unit and integrations tests.

Definition of Done

  1. assert function to check all grafana dashbords in relation data bag.
  2. helper function to get all grafana_dashboards.
  3. Implementation needs to be tested.
syncronize-issues-to-jira[bot] commented 1 month ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/KF-5855.

This message was autogenerated