Giter VIP home page Giter VIP logo

testing-framework's Introduction

Hi there, I'm Samier - aka sbarguil 👋

I'm a Engineer, Triathlete, Developer, and Teacher!!

  • 🔭 I´ve finished my PhD.
  • I’m currently learning to enhance my communication skils 🌱.
  • I’m looking to collaborate with others in Network Automation and SDN.
  • Swim, Bike and Run Strava

Connect with me:

codeSTACKr | LinkedIn codeSTACKr | Instagram




testing-framework's People

Contributors

crcampos612 avatar danielhbar avatar danielhernandezb avatar j-suarezp avatar javierb10 avatar jlopezm2 avatar josemtnzjmnz avatar juan-suarez-wipro avatar luciaob avatar pauloaoki avatar sbarguil avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

testing-framework's Issues

Tear down after test execution

After the execution of the test, leave the modified fields as they were before testing. If the object was not created before the test, that object should be deleted in the tear down

Review the not implemented tests in test_ni_ospf.py --> TestNetworkInstancesOSPF class

Tests skipped

  • test_ni_ospf_subinterface: It needs a subinterface to be referenced. error: ncclient.operations.rpc.RPCError: illegal reference /network-instances/network-instance[name='Prueba_LxVPN']/protocols/protocol[identifier='oc-pol-types:OSPF'][name='OSPF_1']/ospfv2/areas/area[identifier='0.0.0.0']/interfaces/interface[id='1']/interface-ref/config/subinterface

Review the not implemented tests in test_rp_policy_def.py --> TestRoutingPolicyPolicyDef class

Skipped test

  • test_rp_policy_def_match_set_options: Error, tag bgp-conditions not known. ncclient.operations.rpc.RPCError: {'type': 'application', 'tag': 'unknown-element', 'app_tag': None, 'severity': 'error', 'info': 'match-ext-community-set\n\n', 'path': '\n /rpc/edit-config/config/oc-rpol:routing-policy/oc-rpol:policy-definitions/oc-rpol:policy-definition/oc-rpol:statements/oc-rpol:statement/oc-rpol:conditions/oc-bgp-pol:bgp-conditions\n ', 'message': None}

Review the skipped tests in test_if_config.py --> TestInterfacesConfig class

Skipped tests:

  • test_if_config_loopback_mode: Execution not tested, lab routers cisco and juniper doesn't allow to change the param
  • test_if_config_tpid: Execution not tested, lab routers cisco and juniper doesn't allow to change the param
  • test_if_config_type: This test is being skipped. It might need an individual implementation in order to get the prefix of the param tested from the first get config and use it in the edit-config

Review the skipped tests in test_if_subif.py --> TestInterfacesSubInterface class

Skipped tests

  • test_if_subif_ip_state: Before a get to the ip, the subinterface has to be created, so it needs another rpc
  • test_if_subif_origin: Before a get to the origin, the subinterface has to be created, so it needs another rpc
  • test_if_subif_dhcp_client: An exception has occurred when performing the edit_config operation. ncclient.operations.rpc.RPCError: {'type': 'protocol', 'tag': 'unknown-element', 'app_tag': None, 'severity': 'error', 'info': 'rpc\n\n', 'path': '\n /rpc\n ', 'message': None}
  • test_if_subif_mtu: An exception has occurred when performing the edit_config operation. ncclient.operations.rpc.RPCError: {'type': 'protocol', 'tag': 'unknown-element', 'app_tag': None, 'severity': 'error', 'info': 'rpc\n\n', 'path': '\n /rpc\n ', 'message': None}

Review the skipped tests in test_ni_t_ldp.py --> TestNetworkInstancesTLDP class

Skipped tests

  • test_ni_t_ldp_afi_name: Incomplete template, error: ncclient.operations.rpc.RPCError: /network-instances/network-instance[name='Prueba_LxVPN']/mpls: the 'when' expression './config/type = 'oc-ni-types:DEFAULT_INSTANCE''' failed
  • test_ni_t_ldp_remote_address: Incomplete template, error: ncclient.operations.rpc.RPCError: /network-instances/network-instance[name='Prueba_LxVPN']/mpls: the 'when' expression './config/type = 'oc-ni-types:DEFAULT_INSTANCE''' failed
  • test_ni_t_ldp_local_address: Incomplete template, error: ncclient.operations.rpc.RPCError: /network-instances/network-instance[name='Prueba_LxVPN']/mpls: the 'when' expression './config/type = 'oc-ni-types:DEFAULT_INSTANCE''' failed
  • test_ni_t_ldp_enabled: Incomplete template, error: ncclient.operations.rpc.RPCError: /network-instances/network-instance[name='Prueba_LxVPN']/mpls: the 'when' expression './config/type = 'oc-ni-types:DEFAULT_INSTANCE''' failed

Selective test run

Date: 02/10/2020

Username: Javier Benito

Issue: Selective test run

As a:

Currently, we have three ways to run the tests, By block, e.g.

  • python execute_sub_set.py tests/hardware
  • python execute_sub_set.py tests/network_instance

By YML, e.g.

  • python execute_sub_set.py tests/hardware/test_hw_config.py
  • python execute_sub_set.py tests/hardware/test_hw_cpu.py

or by specific testcase, e.g.

  • python execute_sub_set.py tests/hardware/test_hw_component.py:TestHardwareComponent::test_hw_component_description

I want:

The tool should have an interface where you can select which test you want to run:

  • Being able to select a complete block and if you want, several specific testcases of other blocks
  • Select the specific testcases of each block and only run those

So that:

This application will save time when testing in the different phases of testing because you can select the tests to launch faster instead of having to search for the specific command

Accept Criteria:

Testing tool.

Review the skipped tests in test_if_ethernet.py --> TestInterfacesEthernet class

Skipped tests:

  • if_ethernet_aggregate_id
    • "error in cisco: Error in cisco: RPCError: The requested operation failed."
    • "error in juniper: ncclient.operations.rpc.RPCError: error: invalid interface type: 1 - error: statement creation failed - error: load failure on translation changes")
  • if_ethernet_port_speed
    • "error in cisco: ncclient.operations.rpc.RPCError: 'GIRO' detected the 'warning' condition 'The configuration is not supported on this interface"
    • "error in juniper: ncclient.operations.rpc.RPCError: error: invalid interface type: 1 - error: statement creation failed - error: load failure on translation changes")
  • if_ethernet_duplex_mode
    • "error in cisco: ncclient.operations.rpc.RPCError: 'GIRO' detected the 'warning' condition 'The configuration is not supported on this interface"
    • "error in juniper: ncclient.operations.rpc.RPCError: error: invalid interface type: 1 - error: statement creation failed - error: load failure on translation changes")
  • if_ethernet_auto_negotiate:
    • "error in cisco: ncclient.operations.rpc.RPCError: 'GIRO' detected the 'warning' condition 'The configuration is not supported on this interface"
    • "error in juniper: ncclient.operations.rpc.RPCError: error: invalid interface type: 1 - error: statement creation failed - error: load failure on translation changes")

Update:

Skipped tests:

  • if_ethernet_aggregate_id
    • "error in cisco: Error in cisco: RPCError: The requested operation failed."
    • When there is a aggregate previously created: ncclient.operations.rpc.RPCError: Bundle membership configuration conflicts with underlying interface configuration (either already existing or also present in the same commit). Conflicting: /ipv4/io/address/primary
    • "error in juniper: ncclient.operations.rpc.RPCError: error: invalid interface type: 1 - error: load failure on translation changes")

Tests creation

Implement a way to quickly insert or modify tests from the XML template for IP tests

Execute multiple rpcs in a test case for testing different param values

Example

- testcase:
      name: if_ethernet_duplex_mode
      id: 2
      description: >
          This test is to define the duplex mode in an interface.
      rpcs:
          - template: if_ethernet_duplex_mode.xml
            target: candidate
            operation: edit-config
            commit: true
            params:
                   name: "GigabitEthernet0/0/0/4"
                   duplex_mode: "FULL"
      rpcs:
          - template: if_ethernet_duplex_mode.xml
            target: candidate
            operation: edit-config
            commit: true
            params:
                   name: "GigabitEthernet0/0/0/4"
                   duplex_mode: "HALF"

XML schema comparation according to Openconfig models.

Date: 02/10/2020

Username: Daniel Hernández

Issue: XML Schema comparison according to Openconfig models. #125

As a:

Currently, we don't have a tool to compare any OC standards models with the vendor implementation.

Each network equipment has yang files charged in a folder, each yang files corresponding with the vendor implementation of OC models.

For example, there is an OC model (openconfig-routing-policy.yang) and the vendor implementation is (oc-routing-policy.yang).

At this moment we must review manually the correct standard compliance (paths of the parameters, parameters mandatories, value types) and compare with the corresponding OC model.

And determine the implementation deviation percentage of each vendor with their details and knows which one's parameters it does not support.

I want:

A tool that compares the OC Models standard with the implementation vendors OC, introducing both model's paths and generate an excel report with the below information:

  • Deviation percentage according to differences like a (paths of parameters, parameters mandatories, and value types).

  • List of differences (path of parameters, parameters mandatories, and value types.) showing which one is the correct path and the incorrect path, correct parameters mandatories and incorrect parameters mandatories, correct value types, and incorrect value types.

  • Which parameters are missing in the OC model implementation of the vendor.

This must compare with the standard OC models.

So that:

It will permit, that we will know the real support percentage of vendors per model and determine which parameters are supported or has any deviation to make the XML and YML according to this information. Other benefits without a doubt are the time that we must spend looking for parameter deviations.

Accept Criteria:

Testing tool.

Consolidate code from vendor branches after finishing first round of tests

Now we have multiple branches, one per vendor.

For the results, just create a folder per vendor instead of using the same folder in different branches.

For the code, examine in detail the differences for each vendor and create "profiles" or "plugins" for the parts of the code that require adaptation.

Review the skipped tests in test_if_gre.py --> TestInterfacesGre class

Skipped tests:

  • if_gre_dst
    "It seams devices doesn't support the creation of gre tunnels"
  • if_gre_src
    "It seams devices doesn't support the creation of gre tunnels"
  • if_gre_ttl
    "It seams devices doesn't support the creation of gre tunnels"
  • if_gre_ip_prefix_length
    "It seams devices doesn't support the creation of gre tunnels"
  • if_gre_mtu
    "It seams devices doesn't support the creation of gre tunnels"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.