cisco / cisco-network-puppet-module

Apache License 2.0
55 stars 68 forks source link

(FM-7812) Fix negative tests #544

Closed willmeek closed 5 years ago

willmeek commented 5 years ago

As highlighted by utilitylib fix

mikewiebe commented 5 years ago

@willmeek Already fixed.

willmeek commented 5 years ago

@mikewiebe I've reopened this. It may just be a case of cherry picking:

cisco_snmp_community 3.1 needs the stderr:

12:02:08 * TestStep :: 3.1 Negative Properties [ensure => present] :: MANIFEST 12:02:08 test_manifest :: manifest: 12:02:08 0 12:02:08 test_manifest :: check puppet apply cmd (code: [2, 4]) 12:02:08 12:02:16 cisco_snmp_community { 'test': 12:02:16 ensure => present, 12:02:16 group => '', 12:02:16 acl => 'aclname', 12:02:16 12:02:16 } 12:02:16 Notice: Compiled catalog for sut in environment production in 0.11 seconds 12:02:16 Info: Applying configuration version '1550145736' 12:02:16 Error: [#<Cisco::SnmpCommunity:0x000000060ecb98>] The command 'snmp-server community test group ' was rejected with error: 12:02:16 % Invalid command 12:02:16

cisco_tacacs_server 3.1 needs the stderr:

12:08:55 -------- 12:08:55 3.1 negative properties [ensure => present] 12:08:55 format_stepinfo :: (3.1 negative properties) (MANIFEST) 12:08:55 12:08:55 * TestStep :: 3.1 negative properties [ensure => present] :: MANIFEST 12:08:55 test_manifest :: manifest: 12:08:55 0 12:08:55 test_manifest :: check puppet apply cmd (code: [4]) 12:08:55 12:09:03 cisco_tacacs_server { 'default': 12:09:03 ensure => present, 12:09:03 timeout => '-1', 12:09:03 12:09:03 } 12:09:03 Notice: Compiled catalog for sut in environment production in 0.10 seconds 12:09:03 Info: Applying configuration version '1550146141' 12:09:03 Error: [#<Cisco::TacacsServer:0x0000000395dc30>] The command ' tacacs-server timeout -1' was rejected with error: 12:09:03 % Invalid number