Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
IOPSYS
icwmp
Commits
94031d9c
Commit
94031d9c
authored
Feb 03, 2021
by
Vivek Kumar Dutta
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test: Run dependent services before unit test
parent
1df48a41
Pipeline
#11813
failed with stages
in 2 minutes and 46 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
32 additions
and
39 deletions
+32
-39
.gitlab-ci.yml
.gitlab-ci.yml
+2
-1
gitlab-ci/install-dependencies.sh
gitlab-ci/install-dependencies.sh
+4
-37
gitlab-ci/iopsys-supervisord.conf
gitlab-ci/iopsys-supervisord.conf
+9
-0
gitlab-ci/setup.sh
gitlab-ci/setup.sh
+7
-0
gitlab-ci/unit-test.sh
gitlab-ci/unit-test.sh
+10
-1
No files found.
.gitlab-ci.yml
View file @
94031d9c
...
...
@@ -16,9 +16,10 @@ run_unit_test:
allow_failure
:
false
script
:
-
"
./gitlab-ci/install-dependencies.sh"
-
"
./gitlab-ci/setup.sh"
-
"
./gitlab-ci/unit-test.sh"
artifacts
:
when
:
always
paths
:
-
timestamp.log
-
unit-test-coverage.xml
\ No newline at end of file
-
unit-test-coverage.xml
gitlab-ci/install-dependencies.sh
View file @
94031d9c
...
...
@@ -5,46 +5,13 @@ pwd
source
./gitlab-ci/shared.sh
# install libbbf
cd
/opt/dev
rm
-rf
bbf
exec_cmd git clone
-b
devel https://dev.iopsys.eu/iopsys/bbf.git
cd
/opt/dev/bbf
#exec_cmd git checkout a9dff9e62134c3b758afc243eee1da5ed8a0a439
if
[
-n
"
${
UPSTREAM_BBF_SHA
}
"
]
;
then
exec_cmd git checkout
${
UPSTREAM_BBF_SHA
}
fi
echo
"Compiling bbf"
exec_cmd autoreconf
-i
exec_cmd ./configure
--enable-tr181
--enable-tr104
--enable-tr143
--enable-tr157
CPPFLAGS
=
-DCUSTOM_PREFIX
=
\\\"
X_IOPSYS_EU_
\\\"
exec_cmd make
exec_cmd make
install
ldconfig
# configure libbbf
mkdir
-p
/etc/bbfdm/
mkdir
-p
/etc/bbfdm/json
echo
""
>
/etc/bbfdm/dmmap
mkdir
-p
/usr/share/bbfdm
cp
-rf
scripts/functions /usr/share/bbfdm
mkdir
-p
/usr/lib/bbfdm
mkdir
-p
/etc/icwmpd
# install uspd
cd
/opt/dev
rm
-rf
uspd
exec_cmd git clone
-b
devel https://dev.iopsys.eu/iopsys/uspd.git
cd
/opt/dev/uspd
#exec_cmd git checkout a9dff9e62134c3b758afc243eee1da5ed8a0a439
exec_cmd git checkout devel
exec_cmd ./gitlab-ci/install-dependencies.sh
exec_cmd ./gitlab-ci/setup.sh
exec_cmd make
cp
uspd /usr/sbin/uspd
mkdir
-p
/etc/config
mkdir
-p
/etc/init.d
cp test
/uspd/uspd.config /etc/config/uspd
cp test
/uspd/uspd.init /etc/init.d/uspd
/etc/init.d/uspd start
ldconfig
\ No newline at end of file
exec_cmd
cp
uspd /usr/sbin/uspd
gitlab-ci/iopsys-supervisord.conf
0 → 100644
View file @
94031d9c
[
program
:
ubusd
]
command
=/
bin
/
bash
-
c
"/usr/sbin/ubusd"
[
program
:
rpcd
]
command
=/
bin
/
bash
-
c
"/usr/sbin/rpcd"
[
program
:
uspd
]
command
=/
bin
/
bash
-
c
"/usr/sbin/uspd"
gitlab-ci/setup.sh
0 → 100755
View file @
94031d9c
#!/bin/bash
echo
"preparation script"
pwd
cp
./gitlab-ci/iopsys-supervisord.conf /etc/supervisor/conf.d/
gitlab-ci/unit-test.sh
View file @
94031d9c
...
...
@@ -7,11 +7,20 @@ source ./gitlab-ci/shared.sh
trap
cleanup EXIT
trap
cleanup SIGINT
echo
"
Running the unit test cases
"
echo
"
## Compiling icmwp
"
autoreconf
-i
./configure
--enable-acs
=
multi
--enable-acs
=
hdm
make clean
make
check_ret
$?
echo
"## Starting dependent services"
supervisorctl status
supervisorctl restart all
ubus
-t
10 wait_for usp.raw uci
supervisorctl status
echo
"## Running the unit test cases"
./bin/unit_test
check_ret
$?
...
...
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