Skip to content
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
2 changes: 2 additions & 0 deletions app/jobs/reports/irs_credential_tenure_report.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# frozen_string_literal: true

## Note: IrsCredentialTenureReport report is not currently used.

require 'csv'

module Reports
Expand Down
2 changes: 2 additions & 0 deletions app/services/reporting/irs_credential_tenure_report.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# frozen_string_literal: true

## Note: IrsCredentialTenureReport report is not currently used.

module Reporting
class IrsCredentialTenureReport
attr_reader :report_date, :issuers
Expand Down
13 changes: 0 additions & 13 deletions lib/reporting/irs_fraud_metrics_lg99_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,6 @@ def as_emailable_reports
table: lg99_metrics_table,
filename: 'lg99_metrics',
),
Reporting::EmailableReport.new(
title: "IRS Credential Tenure Metric #{stats_month}",
table: credential_tenure_report_metric,
filename: 'Credential_Tenure_Metric',
),
]
end

Expand All @@ -88,7 +83,6 @@ def definitions_table
['Credentials Reinstated', 'Count',
'The count of unique suspended accounts ' + '
that are reinstated within the reporting month.'],
['Credential Tenure', 'Count', 'The average age, in months, of all accounts'],
]
end

Expand Down Expand Up @@ -126,13 +120,6 @@ def lg99_metrics_table
]
end

def credential_tenure_report_metric
Comment thread
shilenpatel1 marked this conversation as resolved.
Reporting::IrsCredentialTenureReport.new(
time_range.end,
issuers: issuers,
).irs_credential_tenure_report
end

def stats_month
time_range.begin.strftime('%b-%Y')
end
Expand Down
12 changes: 0 additions & 12 deletions spec/jobs/reports/irs_fraud_metrics_report_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
"#{report_folder}/definitions.csv",
"#{report_folder}/overview.csv",
"#{report_folder}/lg99_metrics.csv",
"#{report_folder}/Credential_Tenure_Metric.csv",
]
end

Expand All @@ -40,14 +39,6 @@
]
end

let(:mock_credential_tenure_metric) do
[
['Metric', 'Value'],
['Total Users', 5],
['Credential Tenure', 2],
]
end

let(:mock_test_fraud_emails) { ['mock_feds@example.com', 'mock_contractors@example.com'] }
let(:mock_test_fraud_issuers) { ['issuer1'] }

Expand All @@ -69,9 +60,6 @@

allow(report.irs_fraud_metrics_lg99_report).to receive(:lg99_metrics_table)
.and_return(mock_identity_verification_lg99_data)

allow(report.irs_fraud_metrics_lg99_report).to receive(:credential_tenure_report_metric)
.and_return(mock_credential_tenure_metric)
end

it 'sends out a report to just to team data' do
Expand Down
19 changes: 0 additions & 19 deletions spec/lib/reporting/irs_fraud_metrics_lg99_report_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
['Credentials Reinstated', 'Count',
'The count of unique suspended accounts ' + '
that are reinstated within the reporting month.'],
['Credential Tenure', 'Count', 'The average age, in months, of all accounts'],
]
end
let(:expected_overview_table) do
Expand All @@ -34,13 +33,6 @@
['Credentials Reinstated', '1', time_range.begin.to_s, time_range.end.to_s],
]
end
let(:expected_credential_tenure_metric) do
[
['Metric', 'Values'],
['Total Users', '10'],
['Credential Tenure', '15'],
]
end

subject(:report) { Reporting::IrsFraudMetricsLg99Report.new(issuers: [issuer], time_range:) }

Expand Down Expand Up @@ -162,12 +154,6 @@
end

describe '#as_emailable_reports' do
before do
allow_any_instance_of(Reporting::IrsCredentialTenureReport)
.to receive(:irs_credential_tenure_report)
.and_return(expected_credential_tenure_metric)
end

let(:expected_reports) do
[
Reporting::EmailableReport.new(
Expand All @@ -185,11 +171,6 @@
filename: 'lg99_metrics',
table: expected_lg99_metrics_table,
),
Reporting::EmailableReport.new(
title: 'IRS Credential Tenure Metric Jan-2022',
table: expected_credential_tenure_metric,
filename: 'Credential_Tenure_Metric',
),
]
end
it 'return expected table for email' do
Expand Down