diff options
-rw-r--r-- | AUTHORS | 2 | ||||
-rwxr-xr-x | tests/runner.py | 13 |
2 files changed, 14 insertions, 1 deletions
@@ -80,5 +80,5 @@ a license to everyone to use it as detailed in LICENSE.) * Jeff Gilbert <jgilbert@mozilla.com> (copyright owned by Mozilla Foundation) * Frits Talbot <frits@metapathy.com> * Onno Jongbloed <hey@onnoj.net> - +* Jez Ng <me@jezng.com> diff --git a/tests/runner.py b/tests/runner.py index 9db26947..0f8883c8 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -6508,6 +6508,19 @@ Pass: 0.000012 0.000012''') ''' self.do_run(src, '1\n30\n2\n1000000,-123\n') + def test_sscanf_caps(self): + src = r''' + #include "stdio.h" + + int main(){ + unsigned int a; + float e, f, g; + sscanf("a 1.1 1.1 1.1", "%x %E %F %G", &a, &e, &f, &g); + printf("%d %.1F %.1F %.1F\n", a, e, f, g); + } + ''' + self.do_run(src, '10 1.1 1.1 1.1'); + def test_langinfo(self): src = open(path_from_root('tests', 'langinfo', 'test.c'), 'r').read() expected = open(path_from_root('tests', 'langinfo', 'output.txt'), 'r').read() |