From d36ba104a7dee0fbd4e92c6db633bc494eb7c122 Mon Sep 17 00:00:00 2001
From: gbellato <gbellato@localhost>
Date: Fri, 22 Sep 2006 08:30:39 +0000
Subject: [PATCH] Some more data for the schema tests

---
 opends/tests/unit-tests-testng/src/server/org/opends/server/schema/EqualityMatchingRuleTest.java |   52 +++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 51 insertions(+), 1 deletions(-)

diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/schema/EqualityMatchingRuleTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/schema/EqualityMatchingRuleTest.java
index ac7227a..be1fcd1 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/schema/EqualityMatchingRuleTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/schema/EqualityMatchingRuleTest.java
@@ -33,6 +33,7 @@
 import org.testng.annotations.DataProvider;
 import org.testng.annotations.Test;
 
+import static org.opends.server.schema.SchemaConstants.SYNTAX_IA5_STRING_OID;
 import static org.testng.Assert.*;
 
 /**
@@ -44,6 +45,27 @@
   public Object[][] createEqualityMatchingRuleTest()
   {
     return new Object[][] {
+        {"WordEqualityMatchingRule", "first word", "first", true},
+        {"WordEqualityMatchingRule", "first,word", "first", true},
+        {"WordEqualityMatchingRule", "first  word", "first", true},
+        {"WordEqualityMatchingRule", "first#word", "first", true},
+        {"WordEqualityMatchingRule", "first.word", "first", true},
+        {"WordEqualityMatchingRule", "first/word", "first", true},
+        {"WordEqualityMatchingRule", "first$word", "first", true},
+        {"WordEqualityMatchingRule", "first+word", "first", true},
+        {"WordEqualityMatchingRule", "first-word", "first", true},
+        {"WordEqualityMatchingRule", "first=word", "first", true},
+        {"WordEqualityMatchingRule", "word", "first", false},
+        {"WordEqualityMatchingRule", "", "empty", false},
+        {"WordEqualityMatchingRule", "", "", true},
+        
+        {"DirectoryStringFirstComponentEqualityMatchingRule",
+          "(1.2.8.5 NAME 'testtype' DESC 'full type')",
+           "1.2.8.5", true},
+        {"DirectoryStringFirstComponentEqualityMatchingRule",
+             "(1.2.8.5 NAME 'testtype' DESC 'full type')",
+             "something", false},   
+    
         {"BooleanEqualityMatchingRule", "TRUE", "true", true},
         {"BooleanEqualityMatchingRule", "YES", "true", true},
         {"BooleanEqualityMatchingRule", "ON", "true", true},
@@ -103,7 +125,27 @@
         {"BitStringEqualityMatchingRule", "\'1\'B", "\'1\'B", true},
         {"BitStringEqualityMatchingRule", "\'0\'B", "\'1\'B", false},
         
-       
+        {"CaseExactIA5EqualityMatchingRule", "12345678",
+                                             "12345678", true},
+        {"CaseExactIA5EqualityMatchingRule", "ABC45678",
+                                             "ABC45678", true},
+        {"CaseExactIA5EqualityMatchingRule", "ABC45678",
+                                             "abc45678", false},
+                                             
+        {"CaseIgnoreIA5EqualityMatchingRule", "12345678",
+                                              "12345678", true},
+        {"CaseIgnoreIA5EqualityMatchingRule", "ABC45678",
+                                              "ABC45678", true},
+        {"CaseIgnoreIA5EqualityMatchingRule", "ABC45678",
+                                              "abc45678", true},
+                                              
+        {"UniqueMemberEqualityMatchingRule",
+                 "1.3.6.1.4.1.1466.0=#04024869,O=Test,C=GB#'0101'B",
+                 "1.3.6.1.4.1.1466.0=#04024869,O=Test,C=GB#'0101'B", true},
+        {"UniqueMemberEqualityMatchingRule",
+                 "1.3.6.1.4.1.1466.0=#04024869,O=Test,C=GB#'0101'B",
+                 "1.3.6.1.4.1.1466.0=#04024869,o=Test,C=GB#'0101'B", true},
+      
     };
 
   }
@@ -169,6 +211,14 @@
         {"BitStringEqualityMatchingRule", "\'10101"},
         {"BitStringEqualityMatchingRule", "\'1010\'A"},
         
+        {"CaseExactIA5EqualityMatchingRule", "12345678\u2163"},
+        
+        {"CaseIgnoreIA5EqualityMatchingRule", "12345678\u2163"},
+        
+        {"UniqueMemberEqualityMatchingRule",
+                "1.3.6.1.4.1.1466.0=#04024869,O=Test,C=GB#'123'B"},
+        {"UniqueMemberEqualityMatchingRule", "1.3.6.1.4.1.1466.01"}
+        
     };
   }
 

--
Gitblit v1.10.0