~cbehrens/nova/lp844160-build-works-with-zones

« back to all changes in this revision

Viewing changes to vendor/Twisted-10.0.0/twisted/names/test/test_cache.py

  • Committer: Jesse Andrews
  • Date: 2010-05-28 06:05:26 UTC
  • Revision ID: git-v1:bf6e6e718cdc7488e2da87b21e258ccc065fe499
initial commit

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Copyright (c) 2006 Twisted Matrix Laboratories.
 
2
# See LICENSE for details.
 
3
 
 
4
import time
 
5
 
 
6
from twisted.trial import unittest
 
7
 
 
8
from twisted.names import dns, cache
 
9
 
 
10
class Caching(unittest.TestCase):
 
11
    def testLookup(self):
 
12
        c = cache.CacheResolver({
 
13
            dns.Query(name='example.com', type=dns.MX, cls=dns.IN): (time.time(), ([], [], []))})
 
14
        return c.lookupMailExchange('example.com').addCallback(self.assertEquals, ([], [], []))