Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangwenhui
OpenXG-RAN
Commits
6a6e786a
Commit
6a6e786a
authored
Apr 17, 2019
by
Boris Djalal
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Setting variables.
Signed-off-by:
Boris Djalal
<
boris.djalal@eurecom.fr
>
parent
ae680925
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
6 deletions
+14
-6
ci-scripts/test-boris-Jenkinsfile
ci-scripts/test-boris-Jenkinsfile
+14
-6
No files found.
ci-scripts/test-boris-Jenkinsfile
View file @
6a6e786a
...
@@ -43,6 +43,13 @@ def eNB_Branch
...
@@ -43,6 +43,13 @@ def eNB_Branch
def
eNB_CommitID
def
eNB_CommitID
def
eNB_AllowMergeRequestProcess
=
false
def
eNB_AllowMergeRequestProcess
=
false
def
eNB_TargetBranch
def
eNB_TargetBranch
// Global Parameters not to break the main.py command line and code.
def
ADBIPAddress
=
"none"
def
ADBUserName
=
"none"
def
ADBPassword
=
"none"
def
EPCIPAddress
=
"none"
pipeline
{
pipeline
{
agent
{
agent
{
...
@@ -160,10 +167,10 @@ pipeline {
...
@@ -160,10 +167,10 @@ pipeline {
echo
"end if 2"
echo
"end if 2"
// The following parameters are kept not to break the current main.py command line and code.
// The following parameters are kept not to break the current main.py command line and code.
// They should be removed in the future.
// They should be removed in the future.
if
(
params
.
ADB_IPAddress
==
null
)
{
//
if (params.ADB_IPAddress == null) {
params
.
ADB_IPAddress
=
"none"
//
params.ADB_IPAddress = "none"
}
//
}
echo
"params.ADB_IPAddress = ${params.ADB_IPAddress}"
//
echo "params.ADB_IPAddress = ${params.ADB_IPAddress}"
}
}
}
}
}
}
...
@@ -180,6 +187,7 @@ pipeline {
...
@@ -180,6 +187,7 @@ pipeline {
echo
"eNB_CommitID= ${eNB_CommitID}"
echo
"eNB_CommitID= ${eNB_CommitID}"
echo
"eNB_AllowMergeRequestProcess= ${eNB_AllowMergeRequestProcess}"
echo
"eNB_AllowMergeRequestProcess= ${eNB_AllowMergeRequestProcess}"
echo
"params.ADB_IPAddress= ${params.ADB_IPAddress}"
echo
"params.ADB_IPAddress= ${params.ADB_IPAddress}"
echo
"ADB_IPAddress= ${ADB_IPAddress}"
echo
"ADB_Username = ${ADB_Username}"
echo
"ADB_Username = ${ADB_Username}"
echo
"ADB_Password = ${ADB_Password}"
echo
"ADB_Password = ${ADB_Password}"
echo
"eNB_Password = ${eNB_Password}"
echo
"eNB_Password = ${eNB_Password}"
...
@@ -197,12 +205,12 @@ pipeline {
...
@@ -197,12 +205,12 @@ pipeline {
[
$class
:
'UsernamePasswordMultiBinding'
,
credentialsId:
"${params.eNB_Credentials}"
,
usernameVariable:
'eNB_Username'
,
passwordVariable:
'eNB_Password'
],
[
$class
:
'UsernamePasswordMultiBinding'
,
credentialsId:
"${params.eNB_Credentials}"
,
usernameVariable:
'eNB_Username'
,
passwordVariable:
'eNB_Password'
],
[
$class
:
'UsernamePasswordMultiBinding'
,
credentialsId:
"${params.UE_Credentials}"
,
usernameVariable:
'UE_Username'
,
passwordVariable:
'UE_Password'
]
[
$class
:
'UsernamePasswordMultiBinding'
,
credentialsId:
"${params.UE_Credentials}"
,
usernameVariable:
'UE_Username'
,
passwordVariable:
'UE_Password'
]
])
{
])
{
sh
"python3 main.py --mode=InitiateHtml --eNBRepository=${eNB_Repository} --eNBBranch=${eNB_Branch} --eNBCommitID=${eNB_CommitID} --eNB_AllowMerge=${eNB_AllowMergeRequestProcess} --ADBIPAddress=${
params.
ADB_IPAddress} --ADBUserName=${ADB_Username} --ADBPassword=${ADB_Password} --eNBIPAddress=127.0.0.1 --eNBUserName=carabe --eNBPassword=${eNB_Password} ${mainPythonAllXmlFiles}"
sh
"python3 main.py --mode=InitiateHtml --eNBRepository=${eNB_Repository} --eNBBranch=${eNB_Branch} --eNBCommitID=${eNB_CommitID} --eNB_AllowMerge=${eNB_AllowMergeRequestProcess} --ADBIPAddress=${ADB_IPAddress} --ADBUserName=${ADB_Username} --ADBPassword=${ADB_Password} --eNBIPAddress=127.0.0.1 --eNBUserName=carabe --eNBPassword=${eNB_Password} ${mainPythonAllXmlFiles}"
String
[]
myXmlTestSuite
=
testXMLFile
.
split
(
"\\r?\\n"
)
String
[]
myXmlTestSuite
=
testXMLFile
.
split
(
"\\r?\\n"
)
for
(
xmlFile
in
myXmlTestSuite
)
{
for
(
xmlFile
in
myXmlTestSuite
)
{
if
(
fileExists
(
xmlFile
))
{
if
(
fileExists
(
xmlFile
))
{
try
{
try
{
sh
"python3 main.py --mode=TesteNB --eNBIPAddress=${params.eNB_IPAddress} --eNBUserName=${eNB_Username} --eNBPassword=${eNB_Password} --eNBBranch=${eNB_Branch} --eNBSourceCodePath=${params.eNB_SourceCodePath} --eNBRepository=${eNB_Repository} --eNBCommitID=${eNB_CommitID} --ADBIPAddress=${
params.ADB_IPAddress} --EPCIPAddress=${params.
EPC_IPAddress} --XMLTestFile=${xmlFile}"
sh
"python3 main.py --mode=TesteNB --eNBIPAddress=${params.eNB_IPAddress} --eNBUserName=${eNB_Username} --eNBPassword=${eNB_Password} --eNBBranch=${eNB_Branch} --eNBSourceCodePath=${params.eNB_SourceCodePath} --eNBRepository=${eNB_Repository} --eNBCommitID=${eNB_CommitID} --ADBIPAddress=${
ADB_IPAddress} --EPCIPAddress=${
EPC_IPAddress} --XMLTestFile=${xmlFile}"
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
currentBuild
.
result
=
'FAILURE'
currentBuild
.
result
=
'FAILURE'
buildStageStatus
=
false
buildStageStatus
=
false
...
...
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