From 13da2a505a7a7869218a7d487e793e54160cf4a7 Mon Sep 17 00:00:00 2001 From: Steven Rowe Date: Fri, 1 Nov 2013 15:21:38 +0000 Subject: [PATCH] fix regex to ignore XML attribute order git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1537954 13f79535-47bb-0310-9956-ffa450edef68 --- .../solr/rest/schema/TestManagedSchemaFieldResource.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/solr/core/src/test/org/apache/solr/rest/schema/TestManagedSchemaFieldResource.java b/solr/core/src/test/org/apache/solr/rest/schema/TestManagedSchemaFieldResource.java index adcf03f104e..7c679b390e9 100644 --- a/solr/core/src/test/org/apache/solr/rest/schema/TestManagedSchemaFieldResource.java +++ b/solr/core/src/test/org/apache/solr/rest/schema/TestManagedSchemaFieldResource.java @@ -156,7 +156,7 @@ public class TestManagedSchemaFieldResource extends RestTestBase { managedSchemaContents = FileUtils.readFileToString(managedSchemaFile, "UTF-8"); Pattern newfield2StoredTrueIndexedTrueMultiValuedTruePattern = Pattern.compile( ""); + + "(?=.*stored=\"true\")(?=.*indexed=\"true\")(?=.*multiValued=\"true\").*/>"); assertTrue(newfield2StoredTrueIndexedTrueMultiValuedTruePattern.matcher(managedSchemaContents).find()); assertQ("/schema/fields/newfield2?indent=on&wt=xml", @@ -211,7 +211,7 @@ public class TestManagedSchemaFieldResource extends RestTestBase { managedSchemaContents = FileUtils.readFileToString(managedSchemaFile, "UTF-8"); Pattern newfield2StoredTrueIndexedTrueMultiValuedTruePattern = Pattern.compile( ""); + + "(?=.*stored=\"true\")(?=.*indexed=\"true\")(?=.*multiValued=\"true\").*/>"); assertTrue(newfield2StoredTrueIndexedTrueMultiValuedTruePattern.matcher(managedSchemaContents).find()); assertQ("/schema/fields?indent=on&wt=xml",