Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
Production Test Suite
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
9
Issues
9
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Production Test Suite
Commits
c3a0f987
Commit
c3a0f987
authored
Aug 01, 2011
by
Samuel Iglesias Gonsalvez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pts/test/example: added PtsError exception as example
parent
3edff46b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
test00.py
test/example/python/test00.py
+7
-2
No files found.
test/example/python/test00.py
View file @
c3a0f987
...
...
@@ -7,7 +7,7 @@
# Website: http://www.ohwr.org
import
sys
import
rr
# Needed for accessing the rawrabbit driver
#
import rr # Needed for accessing the rawrabbit driver
import
time
import
os
from
ptsexcept
import
*
# Declaration of Exceptions
...
...
@@ -45,7 +45,10 @@ def main (default_directory='.'):
"""
# After loading the firmware, we are ready to access to the registers.
gennum
=
rr
.
Gennum
();
# gennum = rr.Gennum();
# Invented variable.
gennum
=
0
;
# Instantiate CTest.
# The parameters are the Gennum variable and the Wishbone base address
...
...
@@ -57,6 +60,8 @@ def main (default_directory='.'):
# values, etc.
hi
.
hello
(
"world"
)
raise
PtsError
(
'This message shows an error in the application'
);
# This code calls the 'main' function when the program is executed by command-line
# using './test00.py' or 'python test00.py'. In case of importing this Python program
...
...
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