3838# SOFTWARE. 
3939import  copy 
4040import  random 
41+ import  sys 
4142import  unittest 
4243from  collections  import  deque 
4344
@@ -209,6 +210,7 @@ def test_extend(self):
209210        d .extend (d )
210211        self .assertEqual (list (d ), list ('abcdabcd' ))
211212
213+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
212214    def  test_add (self ):
213215        d  =  deque ()
214216        e  =  deque ('abc' )
@@ -265,6 +267,7 @@ def test_getitem(self):
265267        self .assertRaises (IndexError , d .__getitem__ , 0 )
266268        self .assertRaises (IndexError , d .__getitem__ , - 1 )
267269
270+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
268271    def  test_index (self ):
269272        for  n  in  1 , 2 , 30 , 40 , 200 :
270273
@@ -301,11 +304,13 @@ def test_index(self):
301304                    else :
302305                        self .assertEqual (d .index (element , start , stop ), target )
303306
307+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
304308    def  test_index_bug_24913 (self ):
305309        d  =  deque ('A'  *  3 )
306310        with  self .assertRaises (ValueError ):
307311            i  =  d .index ("Hello world" , 0 , 4 )
308312
313+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
309314    def  test_imul (self ):
310315        for  n  in  (- 10 , - 1 , 0 , 1 , 2 , 10 , 1000 ):
311316            d  =  deque ()
@@ -337,6 +342,7 @@ def test_imul(self):
337342            self .assertEqual (d , deque (('abcdef'  *  n )[- 500 :]))
338343            self .assertEqual (d .maxlen , 500 )
339344
345+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
340346    def  test_mul (self ):
341347        d  =  deque ('abc' )
342348        self .assertEqual (d  *  - 5 , deque ())
@@ -586,6 +592,7 @@ def test_roundtrip_iter_init(self):
586592        self .assertNotEqual (id (d ), id (e ))
587593        self .assertEqual (list (d ), list (e ))
588594
595+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
589596    def  test_copy (self ):
590597        mut  =  [10 ]
591598        d  =  deque ([mut ])
@@ -604,6 +611,7 @@ def test_copy(self):
604611                self .assertEqual (d .maxlen , e .maxlen )
605612                self .assertTrue (all (x  is  y  for  x , y  in  zip (d , e )))
606613
614+     @unittest .skipIf (sys .implementation .name  ==  'cpython'  and  sys .version_info [0 :2 ] <  (3 , 5 ), "skipping for cPython versions < 3.5" ) 
607615    def  test_copy_method (self ):
608616        mut  =  [10 ]
609617        d  =  deque ([mut ])
0 commit comments