crypt32/tests: Fix a test failure on Vista and higher.
authorPaul Vriens <Paul.Vriens.Wine@gmail.com>
Wed, 23 Sep 2009 07:08:45 +0000 (09:08 +0200)
committerAlexandre Julliard <julliard@winehq.org>
Wed, 23 Sep 2009 10:34:49 +0000 (12:34 +0200)
dlls/crypt32/tests/chain.c

index a2f537cc6733ad8a258b03d2c3b745f0f6d694dc..27c2d8eeebfaee714ed9cb2c9c3ac827c268b672 100644 (file)
@@ -1686,8 +1686,9 @@ static void testGetCertChain(void)
     ret = pCertGetCertificateChain(NULL, cert, NULL, NULL, &para, 0, NULL,
      &chain);
     ok(!ret, "Expected failure\n");
-    ok(GetLastError() == ERROR_INVALID_DATA,
-     "Expected ERROR_INVALID_DATA, got %u\n", GetLastError());
+    ok(GetLastError() == ERROR_INVALID_DATA ||
+     GetLastError() == CRYPT_E_ASN1_BADTAG, /* Vista and higher */
+     "Expected ERROR_INVALID_DATA or CRYPT_E_ASN1_BADTAG, got %d\n", GetLastError());
 
     CertFreeCertificateContext(cert);