~ubuntu-branches/ubuntu/maverick/python3.1/maverick

« back to all changes in this revision

Viewing changes to Lib/json/tests/test_speedups.py

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2009-03-23 00:01:27 UTC
  • Revision ID: james.westby@ubuntu.com-20090323000127-5fstfxju4ufrhthq
Tags: upstream-3.1~a1+20090322
ImportĀ upstreamĀ versionĀ 3.1~a1+20090322

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
import decimal
 
2
from unittest import TestCase
 
3
 
 
4
from json import decoder
 
5
from json import encoder
 
6
 
 
7
class TestSpeedups(TestCase):
 
8
    def test_scanstring(self):
 
9
        self.assertEquals(decoder.scanstring.__module__, "_json")
 
10
        self.assert_(decoder.scanstring is decoder.c_scanstring)
 
11
 
 
12
    def test_encode_basestring_ascii(self):
 
13
        self.assertEquals(encoder.encode_basestring_ascii.__module__, "_json")
 
14
        self.assert_(encoder.encode_basestring_ascii is
 
15
                          encoder.c_encode_basestring_ascii)