broken SVN status

13 views
Skip to first unread message

uwe.tews

unread,
Dec 28, 2009, 5:40:15 AM12/28/09
to Smarty Developers
Because of some side efects of some update which has been made last
night the SVN is currently not in a working state.

I will let you know when this is fixed.

Uwe

uwe.tews

unread,
Dec 28, 2009, 10:39:00 AM12/28/09
to Smarty Developers
The SVN has been updated now.

Thue Janus Kristensen

unread,
Dec 28, 2009, 1:19:31 PM12/28/09
to smarty-d...@googlegroups.com
I get lots of errors when I run the unit test.

Some of the errors were there before, but the "undefined offset" errors are new.

Regards, Thue

t@k2 ~/.../Smarty3Dev/development> make unit-test
cd PHPunit; phpunit smartytests.php
PHPUnit 3.0.6 by Sebastian Bergmann.

..........
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E..............................
...............F........F.F.F
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
.....
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
..
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
.....
............................
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
F
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
F.
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E........
Notice: Undefined offset:  1 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
.
.........................................
.........................................
.........................................
.............................
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
............
.....................................
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
F..
.........................................
....................
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E.
Notice: Undefined index:  modifier in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 281
E..............
.............
....
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
..
Notice: Undefined offset:  1 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
......
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
.
Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
..............
Notice: Undefined offset:  1 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
F
F........................................
.........................................
.F
Notice: Undefined index:  nocache_hash in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 334


Notice: Undefined index:  nocache_hash in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343

Notice: Undefined offset:  0 in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php on line 343
..

[many, many lines of "Notice: Undefined index:  nocache_hash"]

Time: 00:03

There were 9 errors:

1) testSmartytagInDoubleQuotedString2(DoubleQuotedStringTests)
Exception: Syntax Error in template "string"  on line 1 "{$foo="Hello {counter}{counter} World"}{$foo}" unknown tag "counter"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1930
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:46
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/DoubleQuotedStringTests.php:99

2) testSmartyPhpAllow2(SecurityTests)
Exception: Syntax Error in template "string"  on line 1 "{php} echo "hello world"; {/php}" unknown tag "phpclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:54
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/SecurityTests.php:151

3) testPhpSmartyTagAllowed(CompilePhpTests)
Exception: Syntax Error in template "string"  on line 1 "{php}echo 'hello world'; {/php}" unknown tag "phpclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:54
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompilePhpTests.php:33

4) testBlockPluginNoAssign(CompileBlockPluginTests)
Exception: Syntax Error in template "string"  on line 1 "{textformat}hello world{/textformat}" unknown tag "textformatclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:54
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:32

5) testBlockPluginAssign(CompileBlockPluginTests)
Exception: Syntax Error in template "string"  on line 1 "{textformat assign=foo}hello world{/textformat}{$foo}" unknown tag "textformatclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:46
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:40

6) testBlockPluginFromTemplateFile(CompileBlockPluginTests)
Exception: Syntax Error in template "./templates/blockplugintest.tpl"  on line 1 "{textformat}abc{/textformat}" unknown tag "textformatclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:46
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:48

7) testBlockPluginFromCompiledTemplateFile(CompileBlockPluginTests)
Exception: Syntax Error in template "./templates/blockplugintest.tpl"  on line 1 "{textformat}abc{/textformat}" unknown tag "textformatclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:46
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:57

8) testBlockPluginFromTemplateFileCache(CompileBlockPluginTests)
Exception: Syntax Error in template "./templates/blockplugintest.tpl"  on line 1 "{textformat}abc{/textformat}" unknown tag "textformatclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:46
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:68

9) testBlockPluginRepeat(CompileBlockPluginTests)
Exception: Syntax Error in template "string"  on line 1 "{testblock}{/testblock}" unknown tag "testblockclose"
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:222
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:1981
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2307
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templateparser.php:2407
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_smartytemplatecompiler.php:54
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_templatecompilerbase.php:80
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:257
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:514
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/Smarty.class.php:308
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileBlockPluginTests.php:85
There were 14 failures:

1) testGetCompiledFilepath(FileResourceTests)
Failed asserting that <string:./templates_c/2336794304.file.helloworld.tpl.php> is equal to <string:./templates_c/91205107.file.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:107

2) testGetCachedFilepath(FileResourceTests)
Failed asserting that <string:./cache/2336794304.helloworld.tpl.php> is equal to <string:./cache/91205107.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:193

3) testGetCachedTimestamp(FileResourceTests)
Failed asserting that <boolean:false> is identical to <boolean:true>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:213

4) testGetCachedContent(FileResourceTests)
Failed asserting that <text> is equal to <string:test>.
--- Expected
+++ Actual
@@ -1 +1,4 @@
-test
\ No newline at end of file
+
+Warning: Smarty_Internal_CacheResource_File::include(./cache/2336794304.helloworld.tpl.php): failed to open stream: No such file or directory in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_cacheresource_file.php on line 55
+
+Warning: Smarty_Internal_CacheResource_File::include(): Failed opening './cache/2336794304.helloworld.tpl.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_cacheresource_file.php on line 55

/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:232

5) testSmartyPhpQuote2(SecurityTests)
Failed asserting that <string:Syntax Error in template "string"  on line 1 "{php}echo 'hello world'; {/php}" unknown tag "phpclose"> contains "{php} is deprecated".
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/SecurityTests.php:118

6) testSmartyPhpRemove(SecurityTests)
Failed asserting that <string:Syntax Error in template "string"  on line 1 "{php}echo 'hello world'; {/php}" unknown tag "phpclose"> contains "{php} is deprecated".
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/SecurityTests.php:134

7) testPhpSmartyTagNotAllowed(CompilePhpTests)
Failed asserting that <string:Syntax Error in template "string"  on line 1 "{php}echo 'hello world'; {/php}" unknown tag "phpclose"> contains "{php} is deprecated".
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompilePhpTests.php:41

8) testNocacheCachingYes1(CompileNocacheTests)
Failed asserting that <text> contains "include 4A".
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileNocacheTests.php:52

9) testNocacheCachingYes2(CompileNocacheTests)
Failed asserting that <text> contains "include 6A".
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CompileNocacheTests.php:63

10) testGetCachedFilepath(PhpResourceTests)
Failed asserting that <string:./cache/2000775531.phphelloworld.php.php> is equal to <string:./cache/384701014.phphelloworld.php.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/PhpResourceTests.php:115

11) testGetCachedFilepathSubDirs(CacheResourceFileTests)
Failed asserting that <string:./cache/23/36/79/2336794304.helloworld.tpl.php> is equal to <string:./cache/91/20/51/91205107.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:33

12) testGetCachedFilepathCacheId(CacheResourceFileTests)
Failed asserting that <string:./cache/foo/bar/23/36/79/2336794304.helloworld.tpl.php> is equal to <string:./cache/foo/bar/91/20/51/91205107.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:44

13) testGetCachedFilepathCompileId(CacheResourceFileTests)
Failed asserting that <string:./cache/blar/23/36/79/2336794304.helloworld.tpl.php> is equal to <string:./cache/blar/91/20/51/91205107.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:55

14) testGetCachedFilepathCacheIdCompileId(CacheResourceFileTests)
Failed asserting that <string:./cache/foo/bar/blar/23/36/79/2336794304.helloworld.tpl.php> is equal to <string:./cache/foo/bar/blar/91/20/51/91205107.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:66

FAILURES!
Tests: 571, Failures: 14, Errors: 9.
make: *** [unit-test] Error 2


--

You received this message because you are subscribed to the Google Groups "Smarty Developers" group.
To post to this group, send email to smarty-d...@googlegroups.com.
To unsubscribe from this group, send email to smarty-develop...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/smarty-developers?hl=en.



uwe.tews

unread,
Dec 28, 2009, 1:39:40 PM12/28/09
to Smarty Developers
Thue

This must be something at your place. I just tested to checkout in a
new folder and everything works fine.

Regards Uwe

> /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_template.php:415 ...
>
> read more »

Thue Janus Kristensen

unread,
Dec 28, 2009, 1:42:12 PM12/28/09
to smarty-d...@googlegroups.com
There have always been some of the unit tests which failed in my checkout. Do they all return success for you?

Regards, Thue

uwe.tews

unread,
Dec 28, 2009, 3:03:53 PM12/28/09
to Smarty Developers
They all run through okay in my place.

On Dec 28, 7:42 pm, Thue Janus Kristensen <thu...@gmail.com> wrote:
> There have always been some of the unit tests which failed in my checkout.
> Do they all return success for you?
>
> Regards, Thue
>

> ...
>
> read more »

Thue Janus Kristensen

unread,
Jan 1, 2010, 12:44:20 PM1/1/10
to smarty-d...@googlegroups.com
For example the test in FileResourceTests.php line 107

    public function testGetCompiledFilepath()
    {
        $tpl = $this->smarty->createTemplate('helloworld.tpl');
        $this->assertEquals('./templates_c/4bf4a289c4129184fbd543f317e3a064a0574e1c.file.helloworld.tpl.php', str_replace('\\','/',$tpl->getCompiledFilepath()));
    }

I get the result

   1) testGetCompiledFilepath(FileResourceTests)
   Failed asserting that <string:./templates_c/d09893dcb99d006e5dc24c072259b7fbe0daf635.file.helloworld.tpl.php> is equal to <string:./templates_c/4bf4a289c4129184fbd543f317e3a064a0574e1c.file.helloworld.tpl.php>.
   /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:108

But the path to helloworld.tpl is "./templates/helloworld.tpl", which does have sha1("./templates/helloworld.tpl")=d09893dcb99d006e5dc24c072259b7fbe0daf635 . Which path is the 4bf4a289c4129184fbd543f317e3a064a0574e1c calculated from?

A better unit test could be something like
    public function testGetCompiledFilepath()
    {
        $tpl = $this->smarty->createTemplate('helloworld.tpl');
        $expected = './templates_c/'.sha1($this->smarty->template_dir[0].'helloworld.tpl').'.file.helloworld.tpl.php';
        $this->assertEquals(realpath($expected), realpath($tpl->getCompiledFilepath()));
    }

Perhaps it would also be nice to throw in a realpath() before calculating the sha1's over the template filepath? That would guard against a symlink changing, which can leave a relative path name unchanged, but would be caught by realpath(). I have been tripped by this problem in practice in smarty 2 (I have 3 dev environments at work, to be able to work on 3 different things at the same time, and switch between them by adjusting a symlink). So I would very much like this feature/bugfix :).

Regards, Thue

> ...
>
> read more »

Thue Janus Kristensen

unread,
Jan 1, 2010, 4:33:12 PM1/1/10
to smarty-d...@googlegroups.com
The current list of failed unit tests on my system.

(The patch I just sent was applied, so that one problem is not listed below)

Regards, Thue

Smarty3Dev/development/PHPunit> phpunit smartytests.php

PHPUnit 3.0.6 by Sebastian Bergmann.

.........................................
........................F.F.F............
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.F..................FFFF..............

Time: 00:03

There were 8 failures:

1) testGetCachedFilepath(FileResourceTests)
Failed asserting that <string:./cache/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php> is equal to <string:./cache/4bf4a289c4129184fbd543f317e3a064a0574e1c.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:194

2) testGetCachedTimestamp(FileResourceTests)

Failed asserting that <boolean:false> is identical to <boolean:true>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:214

3) testGetCachedContent(FileResourceTests)

Failed asserting that <text> is equal to <string:test>.
--- Expected
+++ Actual
@@ -1 +1,4 @@
-test
\ No newline at end of file
+
+Warning: Smarty_Internal_CacheResource_File::include(./cache/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php): failed to open stream: No such file or directory in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_cacheresource_file.php on line 55
+
+Warning: Smarty_Internal_CacheResource_File::include(): Failed opening './cache/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/distribution/libs/sysplugins/smarty_internal_cacheresource_file.php on line 55

/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/FileResourceTests.php:233

4) testGetCachedFilepath(PhpResourceTests)
Failed asserting that <string:./cache/10cbecd0f556a6b7bb818651ca0094c34e160548.phphelloworld.php.php> is equal to <string:./cache/ff15ff83776840b500e560cbfcb04a7c55dbd3b3.phphelloworld.php.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/PhpResourceTests.php:115

5) testGetCachedFilepathSubDirs(CacheResourceFileTests)
Failed asserting that <string:./cache/d0/98/93/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php> is equal to <string:./cache/4b/f4/a2/4bf4a289c4129184fbd543f317e3a064a0574e1c.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:33

6) testGetCachedFilepathCacheId(CacheResourceFileTests)
Failed asserting that <string:./cache/foo/bar/d0/98/93/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php> is equal to <string:./cache/foo/bar/4b/f4/a2/4bf4a289c4129184fbd543f317e3a064a0574e1c.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:44

7) testGetCachedFilepathCompileId(CacheResourceFileTests)
Failed asserting that <string:./cache/blar/d0/98/93/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php> is equal to <string:./cache/blar/4b/f4/a2/4bf4a289c4129184fbd543f317e3a064a0574e1c.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:55

8) testGetCachedFilepathCacheIdCompileId(CacheResourceFileTests)
Failed asserting that <string:./cache/foo/bar/blar/d0/98/93/d09893dcb99d006e5dc24c072259b7fbe0daf635.helloworld.tpl.php> is equal to <string:./cache/foo/bar/blar/4b/f4/a2/4bf4a289c4129184fbd543f317e3a064a0574e1c.helloworld.tpl.php>.
/home/tjk/kalus3_clean/trunk/lib/Smarty3Dev/development/PHPunit/CacheResourceFileTests.php:66

FAILURES!
Tests: 571, Failures: 8.

Thue Janus Kristensen

unread,
Jan 1, 2010, 6:49:53 PM1/1/10
to smarty-d...@googlegroups.com
Ok, I fixed some of the errors, and made some neccesary, but not sufficient, fixes for the rest. See attached patch.

Now the result on my computer is


Smarty3Dev/development/PHPunit> phpunit smartytests.php
PHPUnit 3.0.6 by Sebastian Bergmann.

.........................................
..........................F..............

.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
......................................

Time: 00:03

There was 1 failure:

1) testGetCachedTimestamp(FileResourceTests)

Failed asserting that <boolean:false> is identical to <boolean:true>.
Smarty3Dev/development/PHPunit/FileResourceTests.php:216

FAILURES!
Tests: 571, Failures: 1.



===== 1) =====
In this one I already added a
        $this->smarty->fetch($tpl); //cache
to make sure it already is in the cache, but it does not seem to be enough. I assume that fetch() needs to be fixed to set the timestamp when fetch() is generating the cache.

Sometimes this test will work, but that is only when a previous run or a previous test accidentally created the cache. Since the tests files are mostly added in random order by the directory iterator, this is not good enough. Perhaps the reset code between tests should be modified to delete any cached files, to avoid false PASSED results.

Regards, Thue
smarty_unit_test_fixes.patch

uwe.tews

unread,
Jan 2, 2010, 7:24:06 AM1/2/10
to Smarty Developers
Patches and some corrections are in the SVN now.

Thue you did forget to use sha1() in
testGetCachedTimestampCachingDisabled. This did create problems on
this and some following tests.

Thanks for making the PHPunit test independed from the loaction is the
installation.

Regards Uwe

>  smarty_unit_test_fixes.patch
> 8KViewDownload

Thue Janus Kristensen

unread,
Jan 2, 2010, 9:19:42 AM1/2/10
to smarty-d...@googlegroups.com
Excellent - everything works now. :)

Yes, I think I forgot to use the system-dependent separator. Thanks for working out the kinks :).

Regards, Thue

Smarty3Dev/development> make unit-test
cd PHPunit; phpunit smartytests.php

PHPUnit 3.0.6 by Sebastian Bergmann.

.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
.........................................
......................................

Time: 00:03


OK (571 tests)


Reply all
Reply to author
Forward
0 new messages