lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jan...@apache.org
Subject [lucene-solr] 03/03: SOLR-12121: Use a different JSON parser for JWTAuthPluginTest after upgrade to Hadoop3
Date Wed, 06 Feb 2019 08:17:45 GMT
This is an automated email from the ASF dual-hosted git repository.

janhoy pushed a commit to branch branch_8x
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git

commit d28ec13b9a977e0fdf1bb10a0fe89c6cb2e2caad
Author: Jan H√łydahl <janhoy@apache.org>
AuthorDate: Wed Feb 6 09:02:24 2019 +0100

    SOLR-12121: Use a different JSON parser for JWTAuthPluginTest after upgrade to Hadoop3
---
 solr/core/src/test/org/apache/solr/security/JWTAuthPluginTest.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/solr/core/src/test/org/apache/solr/security/JWTAuthPluginTest.java b/solr/core/src/test/org/apache/solr/security/JWTAuthPluginTest.java
index 72a908e..10b049e 100644
--- a/solr/core/src/test/org/apache/solr/security/JWTAuthPluginTest.java
+++ b/solr/core/src/test/org/apache/solr/security/JWTAuthPluginTest.java
@@ -44,7 +44,6 @@ import org.junit.After;
 import org.junit.Before;
 import org.junit.BeforeClass;
 import org.junit.Test;
-import org.mortbay.util.ajax.JSON;
 
 import static org.apache.solr.security.JWTAuthPlugin.JWTAuthenticationResponse.AuthCode.AUTZ_HEADER_PROBLEM;
 import static org.apache.solr.security.JWTAuthPlugin.JWTAuthenticationResponse.AuthCode.NO_AUTZ_HEADER;
@@ -398,7 +397,7 @@ public class JWTAuthPluginTest extends SolrTestCaseJ4 {
     plugin.init(testConfig);
     String headerBase64 = plugin.generateAuthDataHeader();
     String headerJson = new String(Base64.base64ToByteArray(headerBase64), StandardCharsets.UTF_8);
-    Map<String,String> parsed = (Map<String, String>) JSON.parse(headerJson);
+    Map<String,String> parsed = (Map<String, String>) Utils.fromJSONString(headerJson);
     assertEquals("solr:admin", parsed.get("scope"));
     assertEquals("http://acmepaymentscorp/oauth/auz/authorize", parsed.get("authorizationEndpoint"));
     assertEquals("solr-cluster", parsed.get("client_id"));


Mime
View raw message