Ticket #10548: 10548-coerce-traceback-doctest.patch

File 10548-coerce-traceback-doctest.patch, 1.0 KB (added by mderickx, 10 years ago)
  • sage/modular/modsym/modsym.py

    # HG changeset patch
    # User Maarten Derickx <m.derickx.student@gmail.com>
    # Date 1300912154 25200
    # Node ID 9d6814f3693c1b435fc71f9af8c5d465a80f2ced
    # Parent  6d25566e4ad5847b615ccdaf9a2af0bedd3a563d
    #10548 add doctests to make sure ticket is fixed
    
    diff -r 6d25566e4ad5 -r 9d6814f3693c sage/modular/modsym/modsym.py
    a b  
    155155        sage: sage.modular.modsym.modsym.ModularSymbols_clear_cache()
    156156        sage: sage.modular.modsym.modsym._cache.keys()
    157157        []
     158       
     159    TESTS:
     160   
     161        Make sure #10548 is fixed
     162        sage: import gc 
     163        sage: m=ModularSymbols(Gamma1(29))
     164        sage: m=[]
     165        sage: ModularSymbols_clear_cache()
     166        sage: gc.collect() # random
     167        3422
     168        sage: a=[x for x in gc.get_objects() if isinstance(x,sage.modular.modsym.ambient.ModularSymbolsAmbient_wtk_g1)]
     169        sage: a
     170        []
     171
    158172    """
    159173    global _cache
    160174    _cache = {}