|
@@ -212,5 +212,151 @@
|
|
|
</comparators>
|
|
|
</test>
|
|
|
|
|
|
+ <test> <!--Tested -->
|
|
|
+ <description>Testing listing directives filtered by pool</description>
|
|
|
+ <test-commands>
|
|
|
+ <cache-admin-command>-addPool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addPool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /baz -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /buz -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-listDirectives -pool pool2</cache-admin-command>
|
|
|
+ </test-commands>
|
|
|
+ <cleanup-commands>
|
|
|
+ <cache-admin-command>-removePool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-removePool pool2</cache-admin-command>
|
|
|
+ </cleanup-commands>
|
|
|
+ <comparators>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>Found 2 entries</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>8 pool2 /baz</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>9 pool2 /buz</expected-output>
|
|
|
+ </comparator>
|
|
|
+ </comparators>
|
|
|
+ </test>
|
|
|
+
|
|
|
+ <test> <!--Tested -->
|
|
|
+ <description>Testing listing directives filtered by path</description>
|
|
|
+ <test-commands>
|
|
|
+ <cache-admin-command>-addPool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addPool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-listDirectives -path /foo</cache-admin-command>
|
|
|
+ </test-commands>
|
|
|
+ <cleanup-commands>
|
|
|
+ <cache-admin-command>-removePool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-removePool pool2</cache-admin-command>
|
|
|
+ </cleanup-commands>
|
|
|
+ <comparators>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>Found 2 entries</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>10 pool1 /foo</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>12 pool2 /foo</expected-output>
|
|
|
+ </comparator>
|
|
|
+ </comparators>
|
|
|
+ </test>
|
|
|
+
|
|
|
+ <test> <!--Tested -->
|
|
|
+ <description>Testing listing directives filtered by path and pool</description>
|
|
|
+ <test-commands>
|
|
|
+ <cache-admin-command>-addPool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addPool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-listDirectives -path /foo -pool pool2</cache-admin-command>
|
|
|
+ </test-commands>
|
|
|
+ <cleanup-commands>
|
|
|
+ <cache-admin-command>-removePool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-removePool pool2</cache-admin-command>
|
|
|
+ </cleanup-commands>
|
|
|
+ <comparators>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>Found 1 entry</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>16 pool2 /foo</expected-output>
|
|
|
+ </comparator>
|
|
|
+ </comparators>
|
|
|
+ </test>
|
|
|
+
|
|
|
+ <test> <!--Tested -->
|
|
|
+ <description>Testing removing a directive</description>
|
|
|
+ <test-commands>
|
|
|
+ <cache-admin-command>-addPool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-removeDirective 18</cache-admin-command>
|
|
|
+ <cache-admin-command>-listDirectives</cache-admin-command>
|
|
|
+ </test-commands>
|
|
|
+ <cleanup-commands>
|
|
|
+ <cache-admin-command>-removePool pool1</cache-admin-command>
|
|
|
+ </cleanup-commands>
|
|
|
+ <comparators>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>Found 1 entry</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>19 pool1 /bar</expected-output>
|
|
|
+ </comparator>
|
|
|
+ </comparators>
|
|
|
+ </test>
|
|
|
+
|
|
|
+ <test> <!--Tested -->
|
|
|
+ <description>Testing removing every directive for a path</description>
|
|
|
+ <test-commands>
|
|
|
+ <cache-admin-command>-addPool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addPool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command>
|
|
|
+ <cache-admin-command>-removeDirectives -path /foo</cache-admin-command>
|
|
|
+ <cache-admin-command>-listDirectives</cache-admin-command>
|
|
|
+ </test-commands>
|
|
|
+ <cleanup-commands>
|
|
|
+ <cache-admin-command>-removePool pool1</cache-admin-command>
|
|
|
+ <cache-admin-command>-removePool pool2</cache-admin-command>
|
|
|
+ </cleanup-commands>
|
|
|
+ <comparators>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>Found 2 entries</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>22 pool1 /bar</expected-output>
|
|
|
+ </comparator>
|
|
|
+ <comparator>
|
|
|
+ <type>SubstringComparator</type>
|
|
|
+ <expected-output>24 pool2 /bar</expected-output>
|
|
|
+ </comparator>
|
|
|
+ </comparators>
|
|
|
+ </test>
|
|
|
+
|
|
|
</tests>
|
|
|
</configuration>
|