@@ -109,19 +109,48 @@ describe 'container.sh'
109109 rollbar::report_error::restore
110110 end # end container::_start_cadvisor_container
111111
112+ describe ' container::_start_node_exporter_container'
113+ local cadvisor_version=' v0.24.1'
114+ stub docker
115+ stub rollbar::report_error
116+
117+ it ' should run docker container'
118+ container::_start_node_exporter_container
119+ docker::called
120+ end
121+
122+ it ' should report errors on failure'
123+ docker::errors
124+ container::_start_node_exporter_container
125+ rollbar::report_error::called
126+ end
127+
128+ it ' should return 1 on failure'
129+ docker::errors
130+ container::_start_node_exporter_container
131+ assert equal " $? " " 1"
132+ end
133+
134+ docker::restore
135+ rollbar::report_error::restore
136+ end # end container::_start_node_exporter_container
137+
112138 describe ' container::start'
113139 stub container::_start_registry_container
114140 stub container::_start_cadvisor_container
141+ stub container::_start_node_exporter_container
115142 stub container::_start_swarm_container
116143
117144 it ' should start all required containers'
118145 container::start
119146 container::_start_registry_container::called
120147 container::_start_cadvisor_container::called
148+ container::_start_node_exporter_container::called
121149 container::_start_swarm_container::called
122150
123151 container::_start_registry_container::restore
124152 container::_start_cadvisor_container::restore
153+ container::_start_node_exporter_container::restore
125154 container::_start_swarm_container::restore
126155 end # end container::start
127156end # container.sh
0 commit comments