old_contents: import pytest
  
  from .common import METRICS
  
  
  @pytest.mark.e2e
  def test_check_ok(dd_agent_check, instance):
      aggregator = dd_agent_check(instance, rate=True)
      for metric in METRICS:
          aggregator.assert_metric(metric)
  
new_contents: import pytest
  
  from datadog_checks.dev.utils import get_metadata_metrics
  
  from .common import METRICS
  
  
  @pytest.mark.e2e
  def test_check_ok(dd_agent_check, instance):
      aggregator = dd_agent_check(instance, rate=True)
      for metric in METRICS:
          aggregator.assert_metric(metric)
  
      aggregator.assert_metrics_using_metadata(get_metadata_metrics())
      aggregator.assert_all_metrics_covered()
  
subject: Add more assertions to coredns e2e test (#9918)