Commit cbae383b authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Merge branch 'develop' of ssh://gifrerenom_labs.etsi.org/tfs/controller into...

Merge branch 'develop' of ssh://gifrerenom_labs.etsi.org/tfs/controller into feat/296-cttc-camara-end-to-end-ci-cd-tests-fail
parents 5a47a26d 15854638
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -92,6 +92,13 @@ spec:
                name: nbiservice
                port:
                  number: 8080
          - path: /()(camara/.*)
            pathType: Prefix
            backend:
              service:
                name: nbiservice
                port:
                  number: 8080
          - path: /()(agent-probes/.*)
            pathType: Prefix
            backend:

my_deploy.sh

100755 → 100644
+0 −0

File mode changed from 100755 to 100644.

+13 −6
Original line number Diff line number Diff line
@@ -47,12 +47,19 @@ message QoSProfile {
  int32 packetErrorLossRate = 16;
}

message QoSProfileList {
  repeated QoSProfile qos_profiles = 1;
}

message ConstraintList {
  repeated context.Constraint constraints = 1;
}

service QoSProfileService {
  rpc CreateQoSProfile            (QoSProfile           ) returns (QoSProfile    ) {}
  rpc UpdateQoSProfile            (QoSProfile           ) returns (QoSProfile    ) {}
  rpc DeleteQoSProfile            (context.QoSProfileId ) returns (context.Empty ) {}
  rpc GetQoSProfile               (context.QoSProfileId ) returns (QoSProfile    ) {}
  rpc GetQoSProfiles                  (context.Empty        ) returns (stream QoSProfile        ) {}
  rpc GetConstraintListFromQoSProfile (QoDConstraintsRequest) returns (stream context.Constraint) {}
  rpc GetQoSProfiles              (context.Empty        ) returns (QoSProfileList) {}
  rpc GetConstraintsFromQoSProfile(QoDConstraintsRequest) returns (ConstraintList) {}
}
+13 −13
Original line number Diff line number Diff line
@@ -47,9 +47,7 @@ KAFKA_IP=$(docker inspect kafka --format "{{.NetworkSettings.Networks.teraflowbr
echo "Kafka IP: $KAFKA_IP"

docker run --name mock_tfs_nbi_dependencies -d -p 10000:10000 \
    --network=teraflowbridge \
    --env BIND_ADDRESS=0.0.0.0 \
    --env BIND_PORT=10000 \
    --network=teraflowbridge --env BIND_ADDRESS=0.0.0.0 --env BIND_PORT=10000 \
    --env LOG_LEVEL=INFO \
    mock_tfs_nbi_dependencies:test

@@ -69,23 +67,25 @@ printf "\n"
sleep 5 # Give extra time to NBI to get ready

docker ps -a
docker logs kafka
#docker logs kafka
docker logs mock_tfs_nbi_dependencies
docker logs nbi

# helpful pytest flags: --log-level=INFO -o log_cli=true --verbose --maxfail=1 --durations=0
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_core.py --junitxml=/opt/results/${IMAGE_NAME}_report_core.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_tfs_api.py --junitxml=/opt/results/${IMAGE_NAME}_report_tfs_api.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_l2vpn.py --junitxml=/opt/results/${IMAGE_NAME}_report_ietf_l2vpn.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_network.py --junitxml=/opt/results/${IMAGE_NAME}_report_ietf_network.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_l3vpn.py --junitxml=/opt/results/${IMAGE_NAME}_report_ietf_l3vpn.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_etsi_bwm.py --junitxml=/opt/results/${IMAGE_NAME}_report_etsi_bwm.xml"
docker exec -i nbi bash -c "coverage report --include='${IMAGE_NAME}/*' --show-missing"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_core.py --junitxml=/opt/results/nbi_report_core.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_tfs_api.py --junitxml=/opt/results/nbi_report_tfs_api.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_l2vpn.py --junitxml=/opt/results/nbi_report_ietf_l2vpn.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_network.py --junitxml=/opt/results/nbi_report_ietf_network.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_ietf_l3vpn.py --junitxml=/opt/results/nbi_report_ietf_l3vpn.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_etsi_bwm.py --junitxml=/opt/results/nbi_report_etsi_bwm.xml"
docker exec -i nbi bash -c "coverage run --append -m pytest --log-level=INFO --verbose nbi/tests/test_camara_qod.py --junitxml=/opt/results/nbi_report_camara_qod.xml"
docker exec -i nbi bash -c "coverage report --include='nbi/*' --show-missing"

#docker logs mock_tfs_nbi_dependencies
#docker logs nbi
docker logs nbi
#docker logs kafka
docker rm -f mock_tfs_nbi_dependencies nbi
docker rm -f nbi
docker rm -f mock_tfs_nbi_dependencies
docker rm -f kafka
docker network rm teraflowbridge

+0 −25
Original line number Diff line number Diff line
#!/bin/bash
# Copyright 2022-2024 ETSI SDG TeraFlowSDN (TFS) (https://tfs.etsi.org/)
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.


PROJECTDIR=`pwd`

cd $PROJECTDIR/src
RCFILE=$PROJECTDIR/coverage/.coveragerc

# Run unitary tests and analyze coverage of code at same time
# helpful pytest flags: --log-level=INFO -o log_cli=true --verbose --maxfail=1 --durations=0
coverage run --rcfile=$RCFILE --append -m pytest --log-level=INFO --verbose \
    nbi/tests/test_etsi_bwm.py
Loading