Skip to content
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

Add 2024 to the funding stream rfp table #1918

Merged
merged 5 commits into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ describe("when creating a project, the project page", () => {

it("allows an admin user to create an EP project", () => {
//add new
cy.fillAndCheckNewProjectForm("Emissions Performance", "2020");
cy.fillAndCheckNewProjectForm("Emissions Performance", "2024");
cy.happoAndAxe("EP Project New Form", "filled", "main");
cy.findByRole("button", { name: /^confirm/i }).click();

// add overview
cy.url().should("include", "/form/0");
cy.findByText("Emissions Performance - 2020");
cy.findByText("Emissions Performance - 2024");
cy.fillOverviewForm(
"first operator legal name (AB1234567)",
"Cement",
Expand Down Expand Up @@ -176,7 +176,7 @@ describe("when creating a project, the project page", () => {
// project overview section
cy.findByText(/RFP Year ID/i)
.next()
.should("have.text", "Emissions Performance - 2020");
.should("have.text", "Emissions Performance - 2024");
cy.findByText(/Operator Name/i)
.next()
.should("have.text", "first operator legal name (AB1234567)");
Expand Down
2 changes: 1 addition & 1 deletion app/cypress/e2e/cif/project-revision/undo-changes.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ describe("when undoing, the project revision page", () => {
}).click();
cy.addOrEditEmissionIntensityReport(
"2022-01-01",
"2022-02-02",
"2022-04-02",
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The datepicker was ending up with March instead of February both locally and in CI, so I tried a different date and that seemed to make it happier

"tCO",
"1",
"2",
Expand Down
9 changes: 9 additions & 0 deletions schema/deploy/tables/funding_stream_rfp_002.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
-- Deploy cif:tables/funding_stream_rfp_002 to pg


begin;

insert into cif.funding_stream_rfp (year, funding_stream_id) values
(2024, 1), (2024, 2);

commit;
7 changes: 7 additions & 0 deletions schema/revert/tables/funding_stream_rfp_002.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
-- Revert cif:tables/funding_stream_rfp_002 from pg

begin;

delete from cif.funding_stream_rfp where year = 2024;

commit;
2 changes: 2 additions & 0 deletions schema/sqitch.plan
Original file line number Diff line number Diff line change
Expand Up @@ -374,3 +374,5 @@ mutations/commit_form_change [mutations/commit_form_change@1.15.0] 2023-11-22T19
@1.16.4 2024-05-15T17:36:42Z Mike Vesprini <mike@button.is> # release v1.16.4
@1.16.5 2024-05-22T23:00:27Z Mike Vesprini <mike@button.is> # release v1.16.5
@1.17.0 2024-05-24T21:29:42Z Mike Vesprini <mike@button.is> # release v1.17.0

tables/funding_stream_rfp_002 2024-05-28T22:41:57Z Brianna Cerkiewicz <briannacerkiewicz@pop-os> # Add 2024 funding streams values to funding_stream_rfp table
2 changes: 1 addition & 1 deletion schema/test/unit/tables/funding_stream_rfp_test.sql
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ select results_eq(
$$
select count(*) from cif.funding_stream_rfp
$$,
ARRAY['10'::bigint],
ARRAY['12'::bigint],
'cif_internal can view all data from funding_stream_rfp'
);

Expand Down
13 changes: 13 additions & 0 deletions schema/verify/tables/funding_stream_rfp_002.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
-- Verify cif:tables/funding_stream_rfp_002 on pg

begin;

do $$
begin
assert (
(select count(*) from cif.funding_stream_rfp where year = 2024) = 2
), 'EP and IA streams have been added for 2024';
end;
$$;

rollback;
Loading