Commit ec438eb4 authored by alexpott's avatar alexpott

Issue #2501635 by olli, Lendude: Fix QueryParameterTest

parent 84214e86
......@@ -48,41 +48,33 @@ public function testGetArgument($options, Request $request, $expected) {
* - third entry: the expected default argument value.
*/
public function providerGetArgument() {
$data = array();
$data = [];
$single[] = array(
'query_param' => 'test',
);
$single[] = new Request(array('test' => 'data'));
$single[] = 'data';
$data[] = $single;
$data[] = [
['query_param' => 'test'],
new Request(['test' => 'data']),
'data',
];
$single[] = array(
'query_param' => 'test',
'multiple' => 'AND'
);
$single[] = new Request(array('test' => array('data1', 'data2')));
$single[] = 'data1+data2';
$data[] = $single;
$data[] = [
['query_param' => 'test', 'multiple' => 'and'],
new Request(['test' => ['data1', 'data2']]),
'data1,data2',
];
$single[] = array(
'query_param' => 'test',
'multiple' => 'OR'
);
$single[] = new Request(array('test' => array('data1', 'data2')));
$single[] = 'data1,data2';
$data[] = $single;
$data[] = [
['query_param' => 'test', 'multiple' => 'or'],
new Request(['test' => ['data1', 'data2']]),
'data1+data2',
];
$single[] = array(
'query_param' => 'test',
'fallback' => 'blub',
);
$single[] = new Request(array());
$single[] = 'blub';
$data[] = $single;
$data[] = [
['query_param' => 'test', 'fallback' => 'blub'],
new Request([]),
'blub',
];
return $data;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment