[pypy-svn] r72898 - pypy/trunk/pypy/module/rctime/test

arigo at codespeak.net arigo at codespeak.net
Fri Mar 26 15:22:55 CET 2010


Author: arigo
Date: Fri Mar 26 15:22:53 2010
New Revision: 72898

Modified:
   pypy/trunk/pypy/module/rctime/test/test_rctime.py
Log:
Add a test for some nonstandard extension.


Modified: pypy/trunk/pypy/module/rctime/test/test_rctime.py
==============================================================================
--- pypy/trunk/pypy/module/rctime/test/test_rctime.py	(original)
+++ pypy/trunk/pypy/module/rctime/test/test_rctime.py	Fri Mar 26 15:22:53 2010
@@ -220,6 +220,14 @@
         exp = '2000 01 01 00 00 00 1 001'
         assert rctime.strftime("%Y %m %d %H %M %S %w %j", (0,)*9) == exp
 
+    def test_strftime_ext(self):
+        import time as rctime
+
+        tt = rctime.gmtime()
+        result = rctime.strftime('%D', tt)
+        if result != '':    # else format not supported and we got ''
+            assert result == rctime.strftime('%m/%d/%y', t)
+
     def test_strftime_bounds_checking(self):
         import time as rctime
         



More information about the Pypy-commit mailing list