Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
bliss
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
527
Issues
527
List
Boards
Labels
Service Desk
Milestones
Jira
Jira
Merge Requests
133
Merge Requests
133
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
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
Bliss
bliss
Commits
132f8eb4
Commit
132f8eb4
authored
Jan 26, 2018
by
Jose Tiago Macara Coutinho
Committed by
Vincent Michel
Mar 02, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pepu: add command line argument to test specific pepu hostname
parent
e6276f0b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
2 deletions
+26
-2
tests/controllers_hw/conftest.py
tests/controllers_hw/conftest.py
+21
-0
tests/controllers_hw/pepu.py
tests/controllers_hw/pepu.py
+5
-2
No files found.
tests/controllers_hw/conftest.py
0 → 100644
View file @
132f8eb4
# -*- coding: utf-8 -*-
#
# This file is part of the bliss project
#
# Copyright (c) 2016 Beamline Control Unit, ESRF
# Distributed under the GNU LGPLv3. See LICENSE for more info.
import
pytest
def
pytest_addoption
(
parser
):
parser
.
addoption
(
"--pepu"
,
help
=
"pepu host name"
)
def
pytest_collection_modifyitems
(
config
,
items
):
if
config
.
getoption
(
'--pepu'
)
is
None
:
for
item
in
list
(
items
):
if
'pepu'
in
item
.
keywords
:
items
.
remove
(
item
)
tests/controllers_hw/pepu.py
View file @
132f8eb4
...
...
@@ -10,10 +10,13 @@ Run with:
import
pytest
from
bliss.controllers.pepu
import
PEPU
,
Signal
,
Trigger
pytestmark
=
pytest
.
mark
.
pepu
@
pytest
.
fixture
def
pepu
():
pepu
=
PEPU
(
'test'
,
{
'tcp'
:
{
'url'
:
'pepudcm2'
}})
def
pepu
(
request
):
hostname
=
request
.
config
.
getoption
(
'--pepu'
)
pepu
=
PEPU
(
'test'
,
{
'tcp'
:
{
'url'
:
hostname
}})
try
:
pepu
.
calc_channels
[
1
].
formula
=
'1.5'
pepu
.
calc_channels
[
2
].
formula
=
'-1.5'
...
...
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