def METHOD_NAME(self):
    cert = certificate_pb2.X509Description()
    cert.der = "hello-wild"
    cert.subject.extend([name_attribute("com.example.*")])
    cert.sha256_hash = 'cert'
    self.db().store_cert_desc(cert, 0, 0)
    cert2 = certificate_pb2.X509Description()
    cert2.der = "hello"
    cert2.subject.extend([name_attribute("com.example.www")])
    cert.sha256_hash = 'cert2'
    self.db().store_cert_desc(cert2, 1, 0)
    matches = [c for c in self.db().scan_certs_by_subject(
            "*.example.com")]
    self.assertEqual(1, len(matches))
    self.assertEqual("hello-wild", matches[0])