Sha256: dec07f6e7932e88ce1800ced1289fec0e2942615842653d15eaefc44044af899
Contents?: true
Size: 886 Bytes
Versions: 37
Compression:
Stored size: 886 Bytes
Contents
require 'kontena/cli/nodes/label_command' require 'kontena/cli/nodes/labels/list_command' describe Kontena::Cli::Nodes::Labels::ListCommand do include ClientHelpers include OutputHelpers before do allow(client).to receive(:get).with('nodes/test-grid/node').and_return(node) end context "for a node without any labels" do let :node do { "id" => 'test-grid/node', "name" => "node", "labels" => [], } end it "outputs nothing" do expect{subject.run(['node'])}.to output_lines [ ] end end context "for a node with labels" do let :node do { "id" => 'test-grid/node', "name" => "node", "labels" => [ 'test=yes', ], } end it "outputs nothing" do expect{subject.run(['node'])}.to output_lines [ 'test=yes', ] end end end
Version data entries
37 entries across 37 versions & 1 rubygems