Add CRUD Milestone on Admin::BudgetInvestment. Rename Checkpoint to Milestone.

This commit is contained in:
taitus
2017-06-22 13:25:17 +02:00
parent beeb5412d7
commit f220952883
20 changed files with 277 additions and 33 deletions

View File

@@ -1,23 +0,0 @@
require 'rails_helper'
describe "Budget::Investment::Checkpoint" do
describe "Validations" do
let(:checkpoint) { build(:budget_investment_checkpoint) }
it "should be valid" do
expect(checkpoint).to be_valid
end
it "should not be valid without a title" do
checkpoint.title = nil
expect(checkpoint).to_not be_valid
end
it "should not be valid without an investment" do
checkpoint.investment_id = nil
expect(checkpoint).to_not be_valid
end
end
end

View File

@@ -0,0 +1,23 @@
require 'rails_helper'
describe "Budget::Investment::Milestone" do
describe "Validations" do
let(:milestone) { build(:budget_investment_milestone) }
it "should be valid" do
expect(milestone).to be_valid
end
it "should not be valid without a title" do
milestone.title = nil
expect(milestone).to_not be_valid
end
it "should not be valid without an investment" do
milestone.investment_id = nil
expect(milestone).to_not be_valid
end
end
end