Back to index

python3.2  3.2.2
Classes | Functions
test.test_range Namespace Reference

Classes

class  RangeTest

Functions

def pyrange
def pyrange_reversed
def test_main

Function Documentation

def test.test_range.pyrange (   start,
  stop,
  step 
)

Definition at line 9 of file test_range.py.

00009 
00010 def pyrange(start, stop, step):
00011     if (start - stop) // step < 0:
00012         # replace stop with next element in the sequence of integers
00013         # that are congruent to start modulo step.
00014         stop += (start - stop) % step
00015         while start != stop:
00016             yield start
00017             start += step

Here is the caller graph for this function:

def test.test_range.pyrange_reversed (   start,
  stop,
  step 
)

Definition at line 18 of file test_range.py.

00018 
00019 def pyrange_reversed(start, stop, step):
00020     stop += (start - stop) % step
00021     return pyrange(stop - step, start - step, -step)
00022 

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 511 of file test_range.py.

00511 
00512 def test_main():
00513     test.support.run_unittest(RangeTest)

Here is the call graph for this function: