-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Vacated Decision Issues from Request Issues #13173
Merged
Merged
Changes from all commits
Commits
Show all changes
41 commits
Select commit
Hold shift + click to select a range
38b1d58
added basic support for creating request issues from selected MTV dec…
8d5c8f3
only create request issues if disposition is grant type
83d41bc
Merge branch 'master' into jc/12373-mtv-create-request-issues
1f4cea5
moved creation of request issues to PostDecisionMotion model;
a9470c4
Merge branch 'master' into jc/12373-mtv-create-request-issues
29af3f7
adjustments to post_decision_motion_updater_spec to allow tests re in…
63ba17f
linting
c3a5296
we now save all MTV issue IDs for "granted" disposition
c4488d2
Merge branch 'master' into jc/12373-mtv-create-request-issues
80cf6b8
we now add all decision issue IDs for full grant in PostDecisionMotio…
b55570f
added test for PostDecisionMotionUpdater adding all vacated_decision_…
84e4cac
linting
18451dc
updated schema to indicate addtl usage of vacated_decision_issue_ids …
84140b9
better logic for populating vacated_decision_issue_ids field in PostD…
4707bfc
fixed wrong naming in disposition check in PostDecisionMotionUpdater
9d6fce1
Merge branch 'master' into jc/12373-mtv-create-request-issues
504fc81
removed superfluous commented line
c0b14b8
moved logic for creating request issue from decision issue to Decisio…
ae016df
began adding new_decision_issue_from! method to RequestIssue
99fcccb
Merge branch 'master' into jc/13069-mtv-create-decision-issues
dc869f3
updated method name in RequestIssue to "create_vacated_decision_issue!"
9c4536f
added code & tests for generating vacated decision issues from PostDe…
425cdf9
adjustments per codeclimate
b98d0c5
Merge branch 'master' into jc/13069-mtv-create-decision-issues
fb34f9d
Merge branch 'master' into jc/13069-mtv-create-decision-issues
f684246
updated various items in DecisionIssue, RequestIssue, & PostDecisionM…
a26e0c9
Merge branch 'master' into jc/13069-mtv-create-decision-issues
ea02577
fixed error in MTV test
74679be
Merge branch 'master' into jc/13069-mtv-create-decision-issues
7d01a8b
began adding PostDecisionMotionController.create_issues endpoint & tests
1e2baaa
added "create_issues" endpoint on PostDecisionMotionsController:
8e78862
linting
cb160e0
removed mistaken commit of modified capybara.rb
jcq be25dff
DecisionIssue.create_contesting_request_issue now adds new request is…
ae0395c
Merge branch 'master' into jc/13069-mtv-create-decision-issues
b9ee9a6
moved calls to create new request & decision issues to PostDecisionMo…
c376303
removed create_issues & related from PostDecisionMotionsController
ba135f4
updated tests in post_decision_motion_spec
5d84d90
removed tests for PostDecisionMotionsController.create_tasks
583d3de
removed unsed route for create_issues off of PostDecisionMotionsContr…
0d24049
Merge branch 'master' into jc/13069-mtv-create-decision-issues
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,7 @@ | |
end | ||
let(:motions_atty) { create(:user, full_name: "Motions attorney") } | ||
let(:appeal) { create(:appeal) } | ||
let(:orig_decision_issues) do | ||
let!(:orig_decision_issues) do | ||
Array.new(3) do | ||
create( | ||
:decision_issue, | ||
|
@@ -65,6 +65,8 @@ | |
expect(task.reload.status).to eq Constants.TASK_STATUSES.completed | ||
verify_vacate_stream | ||
end | ||
|
||
it "should create decision issues on new vacate" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This looks like a stray line |
||
end | ||
|
||
context "when vacate type is straight vacate" do | ||
|
@@ -74,6 +76,7 @@ | |
subject.process | ||
expect(task.reload.status).to eq Constants.TASK_STATUSES.completed | ||
verify_vacate_stream | ||
verify_decision_issues_created | ||
end | ||
|
||
it "saves all decision issue IDs for full grant" do | ||
|
@@ -92,6 +95,8 @@ | |
subject.process | ||
expect(task.reload.status).to eq Constants.TASK_STATUSES.completed | ||
verify_vacate_stream | ||
verify_vacate_stream | ||
verify_decision_issues_created | ||
end | ||
end | ||
|
||
|
@@ -217,9 +222,11 @@ | |
end | ||
end | ||
|
||
def verify_vacate_stream | ||
vacate_stream = Appeal.find_by(stream_docket_number: appeal.docket_number, stream_type: "vacate") | ||
def vacate_stream | ||
Appeal.find_by(stream_docket_number: appeal.docket_number, stream_type: "vacate") | ||
end | ||
|
||
def verify_vacate_stream | ||
expect(vacate_stream).to_not be_nil | ||
expect(vacate_stream.claimant.participant_id).to eq(appeal.claimant.participant_id) | ||
|
||
|
@@ -235,4 +242,13 @@ def verify_vacate_stream | |
|
||
expect(attorney_task).to_not be_nil | ||
end | ||
|
||
def verify_decision_issues_created | ||
motion = PostDecisionMotion.first | ||
request_issues = vacate_stream.request_issues | ||
expect(request_issues.size).to eq(motion.decision_issues_for_vacatur.size) | ||
|
||
decision_issues = vacate_stream.decision_issues | ||
expect(decision_issues.size).to eq(motion.decision_issues_for_vacatur.size) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 👍 |
||
end | ||
end |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is good for now, we'll probably update it in Sandra's ticket to pass in the decision review so it can be used for De Novo's too.