YMS migration to onos-yangtool 1.10

Change-Id: I22ddf23f813840e0afec1e7713a86891f2a52f28
diff --git a/apps/yms/ut/src/test/resources/ydtTestYangFiles/yms-ietf-te-types.yang b/apps/yms/ut/src/test/resources/ydtTestYangFiles/yms-ietf-te-types.yang
new file mode 100644
index 0000000..206346b
--- /dev/null
+++ b/apps/yms/ut/src/test/resources/ydtTestYangFiles/yms-ietf-te-types.yang
@@ -0,0 +1,870 @@
+   module yms-ietf-te-types {
+
+     namespace "urn:ietf:params:xml:ns:yang:ietf-te-types";
+
+     /* Replace with IANA when assigned */
+     prefix "te-types";
+
+     import yms-ietf-inet-types {
+       prefix inet;
+     }
+
+     organization
+       "IETF Traffic Engineering Architecture and Signaling (TEAS)
+        Working Group";
+
+     contact
+       "WG Web:   <http://tools.ietf.org/wg/teas/>
+        WG List:  <mailto:teas@ietf.org>
+
+        WG Chair: Lou Berger
+                  <mailto:lberger@labn.net>
+
+        WG Chair: Vishnu Pavan Beeram
+                  <mailto:vbeeram@juniper.net>
+
+        Editor:   Tarek Saad
+                  <mailto:tsaad@cisco.com>
+
+        Editor:   Rakesh Gandhi
+                  <mailto:rgandhi@cisco.com>
+
+        Editor:   Vishnu Pavan Beeram
+                  <mailto:vbeeram@juniper.net>
+
+        Editor:   Himanshu Shah
+                  <mailto:hshah@ciena.com>
+
+        Editor:   Xufeng Liu
+                  <mailto:xufeng.liu@ericsson.com>
+
+        Editor:   Xia Chen
+                  <mailto:jescia.chenxia@huawei.com>
+
+        Editor:   Raqib Jones
+                  <mailto:raqib@Brocade.com>
+
+        Editor:   Bin Wen
+                  <mailto:Bin_Wen@cable.comcast.com>";
+
+     description
+       "This module contains a collection of generally
+       useful TE specific YANG data type defintions.";
+
+     revision 2016-03-20 {
+       description "Latest revision of TE generic types";
+       reference "RFC3209";
+     }
+
+     identity tunnel-type {
+       description
+         "Base identity from which specific tunnel types are
+         derived.";
+     }
+
+     identity tunnel-p2p {
+       base tunnel-type;
+       description
+         "TE point-to-point tunnel type.";
+     }
+
+     identity tunnel-p2mp {
+       base tunnel-type;
+       description
+         "TE point-to-multipoint tunnel type.";
+     }
+
+     identity state-type {
+       description
+         "Base identity for TE states";
+     }
+
+     identity state-up {
+       base state-type;
+       description
+         "State up";
+     }
+
+     identity state-down {
+       base state-type;
+       description
+         "State down";
+     }
+
+     identity lsp-prot-type {
+       description
+         "Base identity from which LSP protection types are
+         derived.";
+     }
+
+     identity lsp-prot-unprotected {
+       description
+         "LSP protection 'Unprotected'";
+       reference "RFC4872";
+     }
+
+     identity lsp-prot-reroute-extra {
+       description
+         "LSP protection '(Full) Rerouting'";
+       reference "RFC4872";
+     }
+
+     identity lsp-prot-reroute {
+       description
+         "LSP protection 'Rerouting without Extra-Traffic'";
+       reference "RFC4872";
+     }
+
+     identity lsp-prot-1-for-n {
+       description
+         "LSP protection '1:N Protection with Extra-Traffic'";
+       reference "RFC4872";
+     }
+
+     identity lsp-prot-unidir-1-to-1 {
+       description
+         "LSP protection '1+1 Unidirectional Protection'";
+       reference "RFC4872";
+     }
+
+     identity lsp-prot-bidir-1-to-1 {
+       description
+         "LSP protection '1+1 Bidirectional Protection'";
+       reference "RFC4872";
+     }
+
+     identity switching-capabilities {
+       description
+         "Base identity for interface switching capabilities";
+     }
+
+     identity switching-psc1 {
+       base switching-capabilities;
+       description
+         "Packet-Switch Capable-1 (PSC-1)";
+     }
+
+     identity switching-evpl {
+       base switching-capabilities;
+       description
+         "Ethernet Virtual Private Line (EVPL)";
+     }
+
+     identity switching-l2sc {
+       base switching-capabilities;
+       description
+         "Layer-2 Switch Capable (L2SC)";
+     }
+
+     identity switching-tdm {
+       base switching-capabilities;
+       description
+         "Time-Division-Multiplex Capable (TDM)";
+     }
+
+     identity switching-otn {
+       base switching-capabilities;
+       description
+         "OTN-TDM capable";
+     }
+
+     identity switching-dcsc {
+       base switching-capabilities;
+       description
+         "Data Channel Switching Capable (DCSC)";
+     }
+     identity switching-lsc {
+       base switching-capabilities;
+       description
+         "Lambda-Switch Capable (LSC)";
+     }
+
+     identity switching-fsc {
+       base switching-capabilities;
+       description
+         "Fiber-Switch Capable (FSC)";
+     }
+
+     identity lsp-encoding-types {
+       description
+         "Base identity for encoding types";
+     }
+
+     identity lsp-encoding-packet {
+       base lsp-encoding-types;
+       description
+         "Packet LSP encoding";
+     }
+
+     identity lsp-encoding-ethernet {
+       base lsp-encoding-types;
+       description
+         "Ethernet LSP encoding";
+     }
+
+     identity lsp-encoding-pdh {
+       base lsp-encoding-types;
+       description
+         "ANSI/ETSI LSP encoding";
+     }
+
+     identity lsp-encoding-sdh {
+       base lsp-encoding-types;
+       description
+         "SDH ITU-T G.707 / SONET ANSI T1.105 LSP encoding";
+     }
+
+     identity lsp-encoding-digital-wrapper {
+       base lsp-encoding-types;
+       description
+         "Digital Wrapper LSP encoding";
+     }
+
+     identity lsp-encoding-lambda {
+       base lsp-encoding-types;
+       description
+         "Lambda (photonic) LSP encoding";
+     }
+
+     identity lsp-encoding-fiber {
+       base lsp-encoding-types;
+       description
+         "Fiber LSP encoding";
+     }
+
+     identity lsp-encoding-fiber-channel {
+       base lsp-encoding-types;
+       description
+         "FiberChannel LSP encoding";
+     }
+
+     identity lsp-encoding-oduk {
+       base lsp-encoding-types;
+       description
+         "G.709 ODUk (Digital Path)LSP encoding";
+     }
+
+     identity lsp-encoding-optical-channel {
+       base lsp-encoding-types;
+       description
+         "Line (e.g., 8B/10B) LSP encoding";
+     }
+
+     identity lsp-encoding-line {
+       base lsp-encoding-types;
+       description
+         "Line (e.g., 8B/10B) LSP encoding";
+     }
+
+     /* TE basic features */
+     feature p2mp-te {
+       description
+         "Indicates support for P2MP-TE";
+     }
+
+     feature frr-te {
+       description
+         "Indicates support for TE FastReroute (FRR)";
+     }
+
+     feature extended-admin-groups {
+       description
+         "Indicates support for TE link extended admin
+         groups.";
+     }
+
+     feature named-path-affinities {
+       description
+         "Indicates support for named path affinities";
+     }
+
+     feature named-extended-admin-groups {
+       description
+         "Indicates support for named extended admin groups";
+     }
+
+     feature named-srlg-groups {
+       description
+         "Indicates support for named SRLG groups";
+     }
+
+     feature named-path-constraints {
+       description
+         "Indicates support for named path constraints";
+     }
+
+     grouping explicit-route-subobject {
+       description
+         "The explicit route subobject grouping";
+       choice type {
+         description
+           "The explicit route subobject type";
+         case ipv4-address {
+           description
+             "IPv4 address explicit route subobject";
+           leaf v4-address {
+             type inet:ipv4-address;
+             description
+               "An IPv4 address.  This address is
+               treated as a prefix based on the
+               prefix length value below. Bits beyond
+               the prefix are ignored on receipt and
+               SHOULD be set to zero on transmission.";
+           }
+           leaf v4-prefix-length {
+             type uint8;
+             description
+               "Length in bits of the IPv4 prefix";
+           }
+           leaf v4-loose {
+             type boolean;
+             description
+               "Describes whether the object is loose
+               if set, or otherwise strict";
+           }
+         }
+         case ipv6-address {
+           description
+             "IPv6 address Explicit Route Object";
+           leaf v6-address {
+             type inet:ipv6-address;
+             description
+               "An IPv6 address.  This address is
+               treated as a prefix based on the
+               prefix length value below.  Bits
+               beyond the prefix are ignored on
+               receipt and SHOULD be set to zero
+               on transmission.";
+           }
+           leaf v6-prefix-length {
+             type uint8;
+             description
+               "Length in bits of the IPv4 prefix";
+           }
+           leaf v6-loose {
+             type boolean;
+             description
+               "Describes whether the object is loose
+               if set, or otherwise strict";
+           }
+         }
+         case as-number {
+           leaf as-number {
+             type uint16;
+             description "AS number";
+           }
+           description
+             "Autonomous System explicit route subobject";
+         }
+         case unnumbered-link {
+           leaf router-id {
+             type inet:ip-address;
+             description
+               "A router-id address";
+           }
+           leaf interface-id {
+             type uint32;
+             description "The interface identifier";
+           }
+           description
+             "Unnumbered link explicit route subobject";
+           reference
+             "RFC3477: Signalling Unnumbered Links in
+             RSVP-TE";
+         }
+         case label {
+           leaf value {
+             type uint32;
+             description "the label value";
+           }
+           description
+             "The Label ERO subobject";
+         }
+         /* AS domain sequence..? */
+       }
+     }
+
+     grouping record-route-subobject {
+       description
+         "The record route subobject grouping";
+       choice type {
+         description
+           "The record route subobject type";
+         case ipv4-address {
+           leaf v4-address {
+             type inet:ipv4-address;
+             description
+               "An IPv4 address.  This address is
+               treated as a prefix based on the prefix
+               length value below. Bits beyond the
+               prefix are ignored on receipt and
+               SHOULD be set to zero on transmission.";
+           }
+           leaf v4-prefix-length {
+             type uint8;
+             description
+               "Length in bits of the IPv4 prefix";
+           }
+           leaf v4-flags {
+             type uint8;
+             description
+               "IPv4 address sub-object flags";
+             reference "RFC3209";
+           }
+         }
+         case ipv6-address {
+           leaf v6-address {
+             type inet:ipv6-address;
+             description
+               "An IPv6 address.  This address is
+               treated as a prefix based on the
+               prefix length value below. Bits
+               beyond the prefix are ignored on
+               receipt and SHOULD be set to zero
+               on transmission.";
+           }
+           leaf v6-prefix-length {
+             type uint8;
+             description
+               "Length in bits of the IPv4 prefix";
+           }
+           leaf v6-flags {
+             type uint8;
+             description
+               "IPv6 address sub-object flags";
+             reference "RFC3209";
+           }
+         }
+         case label {
+           leaf value {
+             type uint32;
+             description "the label value";
+           }
+           leaf flags {
+             type uint8;
+             description
+               "Label sub-object flags";
+             reference "RFC3209";
+           }
+           description
+             "The Label ERO subobject";
+         }
+       }
+     }
+
+     identity route-usage-type {
+       description
+         "Base identity for route usage";
+     }
+
+     identity route-include-ero {
+       base route-usage-type;
+       description
+         "Include ERO from route";
+     }
+
+     identity route-exclude-ero {
+       base route-usage-type;
+       description
+         "Exclude ERO from route";
+     }
+
+     identity route-exclude-srlg {
+       base route-usage-type;
+       description
+         "Exclude SRLG from route";
+     }
+
+     identity path-metric-type {
+       description
+         "Base identity for path metric type";
+     }
+
+     identity path-metric-te {
+       base path-metric-type;
+       description
+         "TE path metric";
+     }
+
+     identity path-metric-igp {
+       base path-metric-type;
+       description
+         "IGP path metric";
+     }
+
+     identity path-tiebreaker-type {
+       description
+         "Base identity for path tie-breaker type";
+     }
+
+     identity path-tiebreaker-minfill {
+       base path-tiebreaker-type;
+       description
+         "Min-Fill LSP path placement";
+     }
+
+     identity path-tiebreaker-maxfill {
+       base path-tiebreaker-type;
+       description
+         "Max-Fill LSP path placement";
+     }
+
+     identity path-tiebreaker-randoom {
+       base path-tiebreaker-type;
+       description
+         "Random LSP path placement";
+     }
+
+     identity bidir-provisioning-mode {
+       description
+         "Base identity for bidirectional provisioning
+         mode.";
+     }
+
+     identity bidir-provisioning-single-sided {
+       base bidir-provisioning-mode;
+       description
+         "Single-sided bidirectional provioning mode";
+     }
+
+     identity bidir-provisioning-double-sided {
+       base bidir-provisioning-mode;
+       description
+         "Double-sided bidirectional provioning mode";
+     }
+
+     identity bidir-association-type {
+       description
+         "Base identity for bidirectional association type";
+     }
+
+     identity bidir-assoc-corouted {
+       base bidir-association-type;
+       description
+         "Co-routed bidirectional association type";
+     }
+
+     identity bidir-assoc-non-corouted {
+       base bidir-association-type;
+       description
+         "Non co-routed bidirectional association type";
+     }
+
+     identity resource-affinities-type {
+       description
+         "Base identity for resource affinities";
+     }
+
+     identity resource-aff-include-all {
+       base resource-affinities-type;
+       description
+         "The set of attribute filters associated with a
+         tunnel all of which must be present for a link
+         to be acceptable";
+     }
+
+     identity resource-aff-include-any {
+       base resource-affinities-type;
+       description
+         "The set of attribute filters associated with a
+         tunnel any of which must be present for a link
+         to be acceptable";
+     }
+
+     identity resource-aff-exclude-any {
+       base resource-affinities-type;
+       description
+         "The set of attribute filters associated with a
+         tunnel any of which renders a link unacceptable";
+     }
+
+     typedef admin-group {
+       type binary {
+         length 32;
+       }
+       description
+         "Administrative group/Resource class/Color.";
+     }
+
+     typedef extended-admin-group {
+       type binary;
+       description
+         "Extended administrative group/Resource class/Color.";
+     }
+
+     typedef admin-groups {
+       type union {
+         type admin-group;
+         type extended-admin-group;
+       }
+       description "TE administrative group derived type";
+     }
+
+     typedef srlg {
+       type uint32;
+       description "SRLG type";
+     }
+
+     identity path-computation-srlg-type {
+       description
+         "Base identity for SRLG path computation";
+     }
+
+     identity srlg-ignore {
+       base path-computation-srlg-type;
+       description
+         "Ignores SRLGs in path computation";
+     }
+
+     identity srlg-strict {
+       base path-computation-srlg-type;
+       description
+         "Include strict SRLG check in path computation";
+     }
+
+     identity srlg-preferred {
+       base path-computation-srlg-type;
+       description
+         "Include preferred SRLG check in path computation";
+     }
+
+     identity srlg-weighted {
+       base path-computation-srlg-type;
+       description
+         "Include weighted SRLG check in path computation";
+     }
+
+     typedef te-metric {
+       type uint32;
+       description
+         "TE link metric";
+     }
+
+     typedef topology-id {
+       type string {
+         pattern '/?([a-zA-Z0-9\-_.]+)(/[a-zA-Z0-9\-_.]+)*';
+       }
+       description
+         "An identifier for a topology.";
+     }
+
+     /**
+      * TE tunnel generic groupings
+      **/
+
+     /* Tunnel path selection parameters */
+     grouping tunnel-path-selection {
+       description
+         "Tunnel path selection properties grouping";
+       container path-selection {
+         description
+           "Tunnel path selection properties container";
+         leaf topology {
+           type te-types:topology-id;
+           description
+             "The tunnel path is computed using the specific
+             topology identified by this identifier";
+         }
+         leaf cost-limit {
+           type uint32 {
+             range "1..4294967295";
+           }
+           description
+             "The tunnel path cost limit.";
+         }
+         leaf hop-limit {
+           type uint8 {
+             range "1..255";
+           }
+           description
+             "The tunnel path hop limit.";
+         }
+         leaf metric-type {
+           type identityref {
+             base path-metric-type;
+           }
+           default path-metric-te;
+           description
+             "The tunnel path metric type.";
+         }
+         leaf tiebreaker-type {
+           type identityref {
+             base path-tiebreaker-type;
+           }
+           default path-tiebreaker-maxfill;
+           description
+             "The tunnel path computation tie breakers.";
+         }
+         leaf ignore-overload {
+           type boolean;
+           description
+             "The tunnel path can traverse overloaded node.";
+         }
+         uses tunnel-path-affinities;
+         uses tunnel-path-srlgs;
+       }
+     }
+
+     grouping tunnel-path-affinities {
+       description
+         "Path affinities grouping";
+       container tunnel-path-affinities {
+         if-feature named-path-affinities;
+         description
+           "Path affinities container";
+         choice style {
+           description
+             "Path affinities representation style";
+           case values {
+             leaf value {
+               type uint32 {
+                 range "0..4294967295";
+               }
+               description
+                 "Affinity value";
+             }
+             leaf mask {
+               type uint32 {
+                 range "0..4294967295";
+               }
+               description
+                 "Affinity mask";
+             }
+           }
+           case named {
+             list constraints {
+               key "usage";
+               leaf usage {
+                 type identityref {
+                   base resource-affinities-type;
+                 }
+                 description "Affinities usage";
+               }
+               container constraint {
+                 description
+                   "Container for named affinities";
+                 list affinity-names {
+                   key "name";
+                   leaf name {
+                     type string;
+                     description
+                       "Affinity name";
+                   }
+                   description
+                     "List of named affinities";
+                 }
+               }
+               description
+                 "List of named affinity constraints";
+             }
+           }
+         }
+       }
+     }
+
+     grouping tunnel-path-srlgs {
+       description
+         "Path SRLG properties grouping";
+       container tunnel-path-srlgs {
+         description
+           "Path SRLG properties container";
+         choice style {
+           description
+             "Type of SRLG representation";
+           case values {
+             leaf usage {
+               type identityref {
+                 base route-exclude-srlg;
+               }
+               description "SRLG usage";
+             }
+             leaf-list values {
+               type te-types:srlg;
+               description "SRLG value";
+             }
+           }
+           case named {
+             list constraints {
+               key "usage";
+               leaf usage {
+                 type identityref {
+                   base route-exclude-srlg;
+                 }
+                 description "SRLG usage";
+               }
+               container constraint {
+                 description
+                   "Container for named SRLG list";
+                 list srlg-names {
+                   key "name";
+                   leaf name {
+                     type string;
+                     description
+                       "The SRLG name";
+                   }
+                   description
+                     "List named SRLGs";
+                 }
+               }
+               description
+                 "List of named SRLG constraints";
+             }
+           }
+         }
+       }
+     }
+
+     grouping tunnel-bidir-assoc-properties {
+       description
+         "TE tunnel associated bidirectional properties
+         grouping";
+       container bidirectional {
+         description
+           "TE tunnel associated bidirectional attributes.";
+         container association {
+           description
+             "Tunnel bidirectional association properties";
+           leaf id {
+             type uint16;
+             description
+               "The TE tunnel association identifier.";
+           }
+           leaf source {
+             type inet:ip-address;
+             description
+               "The TE tunnel association source.";
+           }
+           leaf global-source {
+             type inet:ip-address;
+             description
+               "The TE tunnel association global
+               source.";
+           }
+           leaf type {
+             type identityref {
+               base bidir-association-type;
+             }
+             default bidir-assoc-non-corouted;
+             description
+               "The TE tunnel association type.";
+           }
+           leaf provisioing {
+             type identityref {
+               base bidir-provisioning-mode;
+             }
+             description
+               "Describes the provisioning model of the
+               associated bidirectional LSP";
+             reference
+               "draft-ietf-teas-mpls-tp-rsvpte-ext-
+               associated-lsp, section-3.2";
+           }
+         }
+       }
+     }
+     /*** End of TE tunnel groupings ***/
+
+     /**
+      * TE interface generic groupings
+      **/
+   }