Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
trs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Taddeüs Kroes
trs
Commits
f42a77ff
Commit
f42a77ff
authored
Feb 20, 2012
by
Taddeus Kroes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Finished new Leiden tests.
parent
54067813
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
17 deletions
+29
-17
tests/test_leiden_oefenopgave_v12.py
tests/test_leiden_oefenopgave_v12.py
+29
-17
No files found.
tests/test_leiden_oefenopgave_v12.py
View file @
f42a77ff
...
@@ -3,8 +3,8 @@ from tests.rulestestcase import RulesTestCase as TestCase, rewrite
...
@@ -3,8 +3,8 @@ from tests.rulestestcase import RulesTestCase as TestCase, rewrite
class
TestLeidenOefenopgaveV12
(
TestCase
):
class
TestLeidenOefenopgaveV12
(
TestCase
):
def
test_1_e
(
self
):
def
test_1_e
(
self
):
return
self
.
assertRewrite
([
for
chain
in
[[
'-2(6x - 4) ^ 2 * x'
,
'-2(6x - 4) ^ 2 * x'
,
'-2(6x - 4)(6x - 4)x'
,
'-2(6x - 4)(6x - 4)x'
,
'(-2 * 6x - 2 * -4)(6x - 4)x'
,
'(-2 * 6x - 2 * -4)(6x - 4)x'
,
'(-12x - 2 * -4)(6x - 4)x'
,
'(-12x - 2 * -4)(6x - 4)x'
,
...
@@ -15,8 +15,20 @@ class TestLeidenOefenopgaveV12(TestCase):
...
@@ -15,8 +15,20 @@ class TestLeidenOefenopgaveV12(TestCase):
'(-72 * x ^ (1 + 1) - 12x * -4 + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ (1 + 1) - 12x * -4 + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ 2 - 12x * -4 + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ 2 - 12x * -4 + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ 2 - -48x + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ 2 - -48x + 8 * 6x + 8 * -4)x'
,
'(-72 * x ^ 2 - -48x + 48x + 8 * -4)x'
,
'(-72 * x ^ 2 + 48x + 8 * 6x + 8 * -4)x'
,
''
,
'(-72 * x ^ 2 + 48x + 48x + 8 * -4)x'
,
''
]
'(-72 * x ^ 2 + (1 + 1) * 48x + 8 * -4)x'
,
]:
'(-72 * x ^ 2 + 2 * 48x + 8 * -4)x'
,
self
.
assertRewrite
(
chain
)
'(-72 * x ^ 2 + 96x + 8 * -4)x'
,
'(-72 * x ^ 2 + 96x - 32)x'
,
'x(-72 * x ^ 2 + 96x) + x * -32'
,
'x * -72 * x ^ 2 + x * 96x + x * -32'
,
'-x * 72 * x ^ 2 + x * 96x + x * -32'
,
'-x * 72 * x ^ 2 + x ^ (1 + 1) * 96 + x * -32'
,
'-x * 72 * x ^ 2 + x ^ 2 * 96 + x * -32'
,
'-x * 72 * x ^ 2 + x ^ 2 * 96 - x * 32'
])
# FIXME: '-x ^ (1 + 2) * 72 + x ^ 2 * 96 - x * 32',
# FIXME: '-x ^ 3 * 72 + x ^ 2 * 96 - x * 32',
# FIXME: '-72x ^ 3 + x ^ 2 * 96 - x * 32',
# FIXME: '-72x ^ 3 + 96x ^ 2 - x * 32',
# FIXME: '-72x ^ 3 + 96x ^ 2 - 32x'])
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment