|
82 | 82 | end
|
83 | 83 | end
|
84 | 84 |
|
85 |
| - describe "vectors" do |
86 |
| - describe "add" do |
87 |
| - subject(:cli) { vectors_command.new(logger: null_logger) } |
| 85 | + describe "vectors#add" do |
| 86 | + subject(:cli) { vectors_command.new(logger: null_logger) } |
88 | 87 |
|
89 |
| - let(:vector_name) { "Page" } |
90 |
| - let(:vectors_command) { described_class.new.class.subcommand_classes["vectors"] } |
| 88 | + let(:vector_name) { "Page" } |
| 89 | + let(:vectors_command) { described_class.new.class.subcommand_classes["vectors"] } |
91 | 90 |
|
92 |
| - context "when adding a vector within an umbrella project" do |
93 |
| - before do |
94 |
| - FileUtils.mkdir_p(File.join(Dir.pwd, "vectors")) |
95 |
| - cli.add(vector_name) |
96 |
| - end |
| 91 | + context "when adding a vector within an umbrella project" do |
| 92 | + before do |
| 93 | + FileUtils.mkdir_p(File.join(Dir.pwd, "vectors")) |
| 94 | + cli.add(vector_name) |
| 95 | + end |
97 | 96 |
|
98 |
| - it "creates a vector configuration file with 'attributes'" do |
99 |
| - config = YAML.safe_load_file(File.join(Dir.pwd, "vectors", "page.yml")) |
100 |
| - expect(config).to have_key("attributes") |
101 |
| - end |
| 97 | + it "creates a vector configuration file with 'attributes'" do |
| 98 | + config = YAML.safe_load_file(File.join(Dir.pwd, "vectors", "page.yml")) |
| 99 | + expect(config).to have_key("attributes") |
102 | 100 | end
|
| 101 | + end |
103 | 102 |
|
104 |
| - context "when outside an umbrella project" do |
105 |
| - it "indicates that the command must be run within a project" do |
106 |
| - expect { vectors_command.new.add(vector_name) } |
107 |
| - .to output(/Not inside a Manifolds umbrella project/).to_stdout |
108 |
| - end |
| 103 | + context "when outside an umbrella project" do |
| 104 | + it "indicates that the command must be run within a project" do |
| 105 | + expect { vectors_command.new.add(vector_name) } |
| 106 | + .to output(/Not inside a Manifolds umbrella project/).to_stdout |
109 | 107 | end
|
110 | 108 | end
|
111 | 109 | end
|
|
0 commit comments