Travis build: 943

This commit is contained in:
Rohit Tanwar
2018-04-14 10:54:46 +00:00
parent c265a93ede
commit 3b9790bd73
17 changed files with 132 additions and 141 deletions

View File

@ -0,0 +1,7 @@
def bubble_sort(lst):
for passnum in range(len(lst) - 1, 0, -1):
for i in range(passnum):
if lst[i] > lst[i + 1]:
temp = lst[i]
lst[i] = lst[i + 1]
lst[i + 1] = temp

View File

@ -0,0 +1,6 @@
import types,functools
from pytape import test
from bubble_sort import bubble_sort
def bubble_sort_test(t):
t.true(isinstance(bubble_sort, (types.BuiltinFunctionType, types.FunctionType, functools.partial)),'<util.read_snippets.<locals>.snippet object at 0x7fc8ea4c6978> is a function')
test('Testing bubble_sort',bubble_sort_test)