Lines Matching refs:helper

27         $helper = new helper_plugin_dataau();
29 $this->assertEquals('', $helper->_cleanData(' ', ''));
30 $this->assertEquals('', $helper->_cleanData('', ''));
31 $this->assertEquals('', $helper->_cleanData(null, ''));
32 $this->assertEquals('', $helper->_cleanData(false, ''));
34 $this->assertEquals('', $helper->_cleanData('', 'dt'));
35 $this->assertEquals('', $helper->_cleanData('this is not a date', 'dt'));
36 $this->assertEquals('1234-01-01', $helper->_cleanData('1234-1-1', 'dt'));
37 $this->assertEquals('1234-01-01', $helper->_cleanData('1234-01-01', 'dt'));
38 $this->assertEquals('%now%', $helper->_cleanData('%now%', 'dt'));
39 $this->assertEquals('', $helper->_cleanData('1234-01-011', 'dt'));
44 $this->assertEquals('tell://bla', $helper->_cleanData('tell://bla', 'url'));
46 $this->assertEquals('bla@bla.de', $helper->_cleanData('bla@bla.de', 'mail'));
47 $this->assertEquals('bla@bla.de bla', $helper->_cleanData('bla@bla.de bla', 'mail'));
48 … $this->assertEquals('bla@bla.de bla word', $helper->_cleanData('bla@bla.de bla word', 'mail'));
49 …$this->assertEquals('bla@bla.de bla bla word', $helper->_cleanData('bla bla@bla.de bla word', 'mai…
50 …$this->assertEquals('bla@bla.de bla bla word', $helper->_cleanData(' bla bla@bla.de bla word ', 'm…
52 $this->assertEquals('123', $helper->_cleanData('123', 'page'));
53 $this->assertEquals('123_123', $helper->_cleanData('123 123', 'page'));
54 $this->assertEquals('123', $helper->_cleanData('123', 'nspage'));
56 $this->assertEquals('test', $helper->_cleanData('test', ''));
58 $this->assertEquals('test', $helper->_cleanData('test', array('type' => '')));
59 … $this->assertEquals('', $helper->_cleanData('test', array('type' => '', 'enum' => 'some other')));
64 $helper = new helper_plugin_dataau();
66 …ls($this->createColumnEntry('type', false, 'type', 'type', 'type', ''), $helper->_column('type'));
67 …s($this->createColumnEntry('types', true, 'type', 'type', 'type', ''), $helper->_column('types'));
68 … $this->assertEquals($this->createColumnEntry('', false, '', '', '', ''), $helper->_column(''));
69 …s->createColumnEntry('type_url', false, 'type', 'type', 'type', 'url'), $helper->_column('type_url…
70 …s->createColumnEntry('type_urls', true, 'type', 'type', 'type', 'url'), $helper->_column('type_url…
72 …ateColumnEntry('type_hidden', false, 'type', 'type', 'type', 'hidden'), $helper->_column('type_hid…
73 …ateColumnEntry('type_hiddens', true, 'type', 'type', 'type', 'hidden'), $helper->_column('type_hid…
75 …teColumnEntry('%title%', false, '%title%', '%title%', 'Page', 'title'), $helper->_column('%title%'…
76 …ColumnEntry('%pageid%', false, '%pageid%', '%pageid%','Title', 'page'), $helper->_column('%pageid%…
77 …eColumnEntry('%class%', false, '%class%', '%class%', 'Page Class', ''), $helper->_column('%class%'…
78 …tmod%', false, '%lastmod%', '%lastmod%', 'Last Modified', 'timestamp'), $helper->_column('%lastmod…
80 …als($this->createColumnEntry('Type', false, 'type', 'Type', 'Type', ''), $helper->_column('Type'));
84 …Entry('trans_urls', true, 'trans', 'trans', 'Translated Title', 'url'), $helper->_column('trans_ur…
87 $helper = new helper_plugin_dataau();
88 …ntry('trans_urls', true, 'trans', 'trans', 'Übersetzter Titel', 'url'), $helper->_column('trans_ur…
93 $helper = new helper_plugin_dataau();
95 $this->assertEquals('value', $helper->_addPrePostFixes('', 'value'));
96 $this->assertEquals('prevaluepost', $helper->_addPrePostFixes('', 'value', 'pre', 'post'));
97 $this->assertEquals('valuepost', $helper->_addPrePostFixes('', 'value', '', 'post'));
98 $this->assertEquals('prevalue', $helper->_addPrePostFixes('', 'value', 'pre'));
99 …$this->assertEquals('prevaluepost', $helper->_addPrePostFixes(array('prefix' => 'pre', 'postfix' =…
102 … $this->assertEquals('envalue', $helper->_addPrePostFixes(array('prefix' => '%lang%'), 'value'));
104 … $this->assertEquals('value', $helper->_addPrePostFixes(array('prefix' => '%trans%'), 'value'));
113 …$this->assertEquals('de:value', $helper->_addPrePostFixes(array('prefix' => '%trans%:'), 'value'));
119 $helper = new helper_plugin_dataau();
121 $this->assertEquals('tom', $helper->_resolveData('tom', 'name'));
122 $this->assertEquals('jerry', $helper->_resolveData('jerry', 'name'));
124 …$this->assertEquals('wiki:syntax Formatting Syntax', $helper->_resolveData('wiki:syntax', 'name_ti…
125 $this->assertEquals('none:existing ', $helper->_resolveData('none:existing', 'name_title'));
133 $helper = new helper_plugin_dataau();
137 $helper->_formatData(array('type' => ''), "value1\n value2\n val", $renderer));
140 $helper->_formatData(array('type' => 'page'), "page", $renderer));
143 $helper->_formatData(array('type' => 'title'), "page|title", $renderer));
146 $helper->_formatData(array('type' => 'pageid'), "page|title", $renderer));
149 $helper->_formatData(array('type' => 'nspage', 'key' => 'key'), "page", $renderer));
153 $helper->_formatData(array('type' => 'mail'), "pa:ge", $renderer));
156 $helper->_formatData(array('type' => 'mail'), "pa:ge some user", $renderer));
160 $helper->_formatData(array('type' => 'mail'), "pa:ge", $renderer));
163 $helper->_formatData(array('type' => 'mail'), "pa:ge some user", $renderer));
166 $helper->_formatData(array('type' => 'url'), "url", $renderer));
169 $helper->_formatData(array('type' => 'tag'), "value", $renderer));
172 $helper->_formatData(array('type' => 'timestamp'), "1234567", $renderer));
175 $helper->_formatData(array('type' => 'wiki'), '|**bla**', $renderer));
179 $helper->_formatData(array('type' => 'img300'), 'wiki:dokuwiki-128.png', $renderer));
184 $helper = new helper_plugin_dataau();
188 $helper->_replacePlaceholdersInSQL($dataau);
193 $helper->_replacePlaceholdersInSQL($dataau);
197 $helper->_replacePlaceholdersInSQL($dataau);
201 $helper->_replacePlaceholdersInSQL($dataau);
217 $helper = new helper_plugin_dataau();
219 $this->assertFalse($helper->_getDB());
223 $helper = new helper_plugin_dataau();
226 , $helper->_parse_filter('name_some = tom'));
229 , $helper->_parse_filter('name = tom'));
232 , $helper->_parse_filter('name != tom'));
235 , $helper->_parse_filter('name <> tom'));
238 , $helper->_parse_filter('name < tom'));
241 , $helper->_parse_filter('name > tom'));
244 , $helper->_parse_filter('name <= tom'));
247 , $helper->_parse_filter('name >= tom'));
250 , $helper->_parse_filter('name ~ tom'));
253 , $helper->_parse_filter('name *~ tom'));
256 , $helper->_parse_filter('name !~ tom'));
259 , $helper->_parse_filter('name ~ *tom'));
262 , $helper->_parse_filter('name ~ tom*'));
265 , $helper->_parse_filter('name ~ *tom*'));
268 , $helper->_parse_filter('name ~~ tom'));
271 , $helper->_parse_filter("name ~~ t'om,john*"));
273 $this->assertEquals(false, $helper->_parse_filter('name is *tom*'));
274 $this->assertEquals(false, $helper->_parse_filter(''));
288 $helper = new helper_plugin_dataau();
290 $this->assertEquals(array(), $helper->_get_filters());
294 $helper->_get_filters());
299 $helper->_get_filters());
340 $plugininstalled = in_array('translation', plugin_list('helper',$all=true));