Commit 112beb31 authored by Manuel Angel Jimenez Quesada's avatar Manuel Angel Jimenez Quesada
Browse files

clean code and add new log at debug level

parent 289187b8
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -53,6 +53,7 @@ include:
  - local: '/src/analytics/.gitlab-ci.yml'
  - local: '/src/qos_profile/.gitlab-ci.yml'
  - local: '/src/vnt_manager/.gitlab-ci.yml'
  - local: '/src/e2e_orchestrator/.gitlab-ci.yml'
  - local: '/src/ztp_server/.gitlab-ci.yml'

  # This should be last one: end-to-end integration tests
+5 −3
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

import grpc, pytest
import grpc, pytest, logging, json
from ztp_server.client.ZtpClient import ZtpClient
from common.proto.ztp_server_pb2 import ProvisioningScriptName, ProvisioningScript, ZtpFileName, ZtpFile

@@ -21,6 +21,9 @@ from .PrepareTestScenario import ( # pylint: disable=unused-import
    ztp_client
)

LOGGER = logging.getLogger(__name__)
LOGGER.setLevel(logging.DEBUG)

def test_GetProvisioningScript(
    ztp_client : ZtpClient,
):  # pylint: disable=redefined-outer-name
@@ -29,6 +32,5 @@ def test_GetProvisioningScript(
    ztp_provisioning_file_request.scriptname = "provisioning_script_sonic.sh" # pylint: disable=no-member
    ztp_reply = ztp_client.GetProvisioningScript(ztp_provisioning_file_request)

    print("ztp_reply: " + str(ztp_reply) ) 

    LOGGER.debug('retrieved_data={:s}'.format(json.dumps(ztp_reply, sort_keys=True)))
    assert ztp_reply.script.startswith("#!/bin/bash")