#273: Remove nose dependency for recursion_dynamic/ (#280)

This commit is contained in:
Donne Martin
2020-07-13 21:26:50 -04:00
committed by GitHub
parent dce6b6aa67
commit 76cb6507fc
57 changed files with 548 additions and 751 deletions

View File

@@ -82,9 +82,7 @@
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"metadata": {},
"outputs": [],
"source": [
"class Permutations(object):\n",
@@ -111,28 +109,26 @@
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"metadata": {},
"outputs": [],
"source": [
"# %load test_permutations.py\n",
"from nose.tools import assert_equal\n",
"import unittest\n",
"\n",
"\n",
"class TestPermutations(object):\n",
"class TestPermutations(unittest.TestCase):\n",
"\n",
" def test_permutations(self):\n",
" permutations = Permutations()\n",
" assert_equal(permutations.find_permutations(None), None)\n",
" assert_equal(permutations.find_permutations(''), '')\n",
" self.assertEqual(permutations.find_permutations(None), None)\n",
" self.assertEqual(permutations.find_permutations(''), '')\n",
" string = 'AABC'\n",
" expected = [\n",
" 'AABC', 'AACB', 'ABAC', 'ABCA',\n",
" 'ACAB', 'ACBA', 'BAAC', 'BACA',\n",
" 'BCAA', 'CAAB', 'CABA', 'CBAA'\n",
" ]\n",
" assert_equal(permutations.find_permutations(string), expected)\n",
" self.assertEqual(permutations.find_permutations(string), expected)\n",
" print('Success: test_permutations')\n",
"\n",
"\n",
@@ -171,9 +167,9 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.5.0"
"version": "3.7.2"
}
},
"nbformat": 4,
"nbformat_minor": 0
"nbformat_minor": 1
}