This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/15511 Change subject: WIP: support for osmo-resmim testsuite ...................................................................... WIP: support for osmo-resmim testsuite Change-Id: I05090f408b04aae24c23978da831e9f844d723a3 --- A ttcn3-remsim-test/.release A ttcn3-remsim-test/Dockerfile A ttcn3-remsim-test/Makefile A ttcn3-remsim-test/REMSIM_Tests.cfg A ttcn3-remsim-test/bankd/REMSIM_Tests.cfg A ttcn3-remsim-test/bankd/bankd_pcsc_slots.csv A ttcn3-remsim-test/client/REMSIM_Tests.cfg A ttcn3-remsim-test/jenkins.sh 8 files changed, 182 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/11/15511/1 diff --git a/ttcn3-remsim-test/.release b/ttcn3-remsim-test/.release new file mode 100644 index 0000000..a036e4f --- /dev/null +++ b/ttcn3-remsim-test/.release @@ -0,0 +1,2 @@ +release=0.0.0 +tag=ttcn3-remsim-test-0.0.0 diff --git a/ttcn3-remsim-test/Dockerfile b/ttcn3-remsim-test/Dockerfile new file mode 100644 index 0000000..b1ea71f --- /dev/null +++ b/ttcn3-remsim-test/Dockerfile @@ -0,0 +1,35 @@ +ARG USER +FROM $USER/debian-stretch-titan + +RUN mkdir /root/projects && (cd /root/projects && ln -sf / git) +RUN git clone git://git.osmocom.org/osmo-ttcn3-hacks.git + +RUN cd osmo-ttcn3-hacks && \ + git checkout -f -B master origin/master && \ + make deps + +RUN git config --global user.email docker at dock.er && \ + git config --global user.name "Dock Er" + +ARG OSMO_TTCN3_BRANCH="master" + +ADD http://git.osmocom.org/osmo-ttcn3-hacks/patch?h=$OSMO_TTCN3_BRANCH /tmp/commit +RUN cd osmo-ttcn3-hacks && \ + git fetch && \ + git checkout $OSMO_TTCN3_BRANCH && \ + (git symbolic-ref -q HEAD && git reset --hard origin/$OSMO_TTCN3_BRANCH || exit 1); \ + git rev-parse --abbrev-ref HEAD && git rev-parse HEAD && \ + make deps-update remsim + +VOLUME /data + +RUN ln -s /osmo-ttcn3-hacks/ttcn3-tcpdump-start.sh / && \ + ln -s /osmo-ttcn3-hacks/ttcn3-tcpdump-stop.sh / + +COPY REMSIM_Tests.cfg /data/REMSIM_Tests.cfg + +CMD cd /data && \ + /osmo-ttcn3-hacks/start-testsuite.sh /osmo-ttcn3-hacks/remsim/REMSIM_Tests; \ + exit_code=$?; \ + /osmo-ttcn3-hacks/log_merge.sh REMSIM_Tests --rm; \ + exit $exit_code diff --git a/ttcn3-remsim-test/Makefile b/ttcn3-remsim-test/Makefile new file mode 100644 index 0000000..0895788 --- /dev/null +++ b/ttcn3-remsim-test/Makefile @@ -0,0 +1,2 @@ + +include ../make/Makefile diff --git a/ttcn3-remsim-test/REMSIM_Tests.cfg b/ttcn3-remsim-test/REMSIM_Tests.cfg new file mode 100644 index 0000000..5a9f026 --- /dev/null +++ b/ttcn3-remsim-test/REMSIM_Tests.cfg @@ -0,0 +1,16 @@ +[ORDERED_INCLUDE] +"/osmo-ttcn3-hacks/Common.cfg" +"/osmo-ttcn3-hacks/remsim/REMSIM_Tests.default" + +[LOGGING] + +[TESTPORT_PARAMETERS] + +[MODULE_PARAMETERS] +# IP address of IUT (server) to which test connects +REMSIM_Tests.mp_server_ip := "172.18.17.20" + +[MAIN_CONTROLLER] + +[EXECUTE] +RemsimServer_Tests.control diff --git a/ttcn3-remsim-test/bankd/REMSIM_Tests.cfg b/ttcn3-remsim-test/bankd/REMSIM_Tests.cfg new file mode 100644 index 0000000..2e77590 --- /dev/null +++ b/ttcn3-remsim-test/bankd/REMSIM_Tests.cfg @@ -0,0 +1,18 @@ +[ORDERED_INCLUDE] +"/osmo-ttcn3-hacks/Common.cfg" +"/osmo-ttcn3-hacks/remsim/REMSIM_Tests.default" + +[LOGGING] + +[TESTPORT_PARAMETERS] + +[MODULE_PARAMETERS] +# IP address on which the simulated server binds +REMSIM_Tests.mp_server_ip := "172.18.17.10" +# IP address of the IUT (bankd) to which simulated client connects +REMSIM_Tests.mp_bankd_ip := "172.18.17.30" + +[MAIN_CONTROLLER] + +[EXECUTE] +RemsimBankd_Tests.control diff --git a/ttcn3-remsim-test/bankd/bankd_pcsc_slots.csv b/ttcn3-remsim-test/bankd/bankd_pcsc_slots.csv new file mode 100644 index 0000000..38a22c9 --- /dev/null +++ b/ttcn3-remsim-test/bankd/bankd_pcsc_slots.csv @@ -0,0 +1,6 @@ +"1","0","ACS ACR33 ICC Reader 00 00" +"1","1","ACS ACR33 ICC Reader 00 01" +"1","2","ACS ACR33 ICC Reader 00 02" +"1","3","ACS ACR33 ICC Reader 00 03" +"1","4","ACS ACR33 ICC Reader 00 04" +"1","23","Alcor Micro AU9560 00 00" diff --git a/ttcn3-remsim-test/client/REMSIM_Tests.cfg b/ttcn3-remsim-test/client/REMSIM_Tests.cfg new file mode 100644 index 0000000..d3f8d42 --- /dev/null +++ b/ttcn3-remsim-test/client/REMSIM_Tests.cfg @@ -0,0 +1,18 @@ +[ORDERED_INCLUDE] +"/osmo-ttcn3-hacks/Common.cfg" +"/osmo-ttcn3-hacks/remsim/REMSIM_Tests.default" + +[LOGGING] + +[TESTPORT_PARAMETERS] +# IP address to which ATS binds emulated remsim-server +REMSIM_Tests.mp_server_ip := "172.18.17.10" +# IP address to which ATS binds emulated remsim-bankd +REMSIM_Tests.mp_bankd_ip := "172.18.17.10" + +[MODULE_PARAMETERS] + +[MAIN_CONTROLLER] + +[EXECUTE] +RemsimClient_Tests.control diff --git a/ttcn3-remsim-test/jenkins.sh b/ttcn3-remsim-test/jenkins.sh new file mode 100755 index 0000000..38da9b3 --- /dev/null +++ b/ttcn3-remsim-test/jenkins.sh @@ -0,0 +1,85 @@ +#!/bin/sh + +. ../jenkins-common.sh +IMAGE_SUFFIX="${IMAGE_SUFFIX:-master}" +docker_images_require \ + "debian-stretch-build" \ + "osmo-remsim-$IMAGE_SUFFIX" \ + "ttcn3-remsim-test" + +start_server() { + echo Starting container with osmo-remsim-server + docker run --rm \ + --network $NET_NAME --ip 172.18.17.20 \ + -v $VOL_BASE_DIR/server:/data \ + --name ${BUILD_TAG}-server -d \ + $REPO_USER/osmo-remsim-$IMAGE_SUFFIX \ + osmo-remsim-server +} + +start_bankd() { + echo Starting container with osmo-remsim-bankd + docker run --rm \ + --network $NET_NAME --ip 172.18.17.30 \ + -v $VOL_BASE_DIR/bankd:/data \ + --name ${BUILD_TAG}-bankd -d \ + $REPO_USER/osmo-remsim-$IMAGE_SUFFIX \ + osmo-remsim-bankd -i 172.18.17.10 +} + +start_client() { + echo Starting container with osmo-remsim-client + docker run --rm \ + --network $NET_NAME --ip 172.18.17.40 \ + -v $VOL_BASE_DIR/client:/data \ + --name ${BUILD_TAG}-client-d \ + $REPO_USER/osmo-remsim-$IMAGE_SUFFIX \ + osmo-remsim-client +} + + + +start_testsuite() { + echo Starting container with REMSIM testsuite + docker run --rm \ + --network $NET_NAME --ip 172.18.17.10 \ + -e "TTCN3_PCAP_PATH=/data" \ + -v $VOL_BASE_DIR/remsim-tester:/data \ + --name ${BUILD_TAG}-ttcn3-remsim-test \ + $REPO_USER/ttcn3-remsim-test +} + +network_create 172.18.17.0/24 + +mkdir $VOL_BASE_DIR/remsim-tester + +mkdir $VOL_BASE_DIR/server + +mkdir $VOL_BASE_DIR/bankd +cp bankd/bankd_pcsc_slots.csv $VOL_BASE_DIR/bankd/ + +mkdir $VOL_BASE_DIR/client + + +# 1) server test suite +start_server +cp REMSIM_Tests.cfg $VOL_BASE_DIR/remsim-tester/ +start_testsuite +docker container kill ${BUILD_TAG}-server + +# 2) bankd test suite +echo "Changing to bankd configuration" +start_bankd +cp bankd/REMSIM_Tests.cfg $VOL_BASE_DIR/remsim-tester/ +start_testsuite +docker container kill ${BUILD_TAG}-bankd + +# 3) client test suite +#echo "Changing to client configuration" +#start_client +#cp client/REMSIM_Tests.cfg $VOL_BASE_DIR/remsim-tester/ +#start_testsuite +#docker container kill ${BUILD_TAG}-client + +network_remove +collect_logs -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/15511 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I05090f408b04aae24c23978da831e9f844d723a3 Gerrit-Change-Number: 15511 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge at gnumonks.org> Gerrit-MessageType: newchange -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190913/f9f9fff2/attachment.htm>