From 606e7842f00fe7ba9cd57e293ecd4f558f1695da Mon Sep 17 00:00:00 2001 From: carolyncole <1599081+carolyncole@users.noreply.github.com> Date: Fri, 20 Dec 2024 12:10:39 -0500 Subject: [PATCH] Updating for additional valid users (#1159) --- data/user_registration_list_development.csv | 4 +++- data/user_registration_list_production.csv | 4 +++- data/user_registration_list_qa.csv | 4 +++- data/user_registration_list_staging.csv | 4 +++- data/user_registration_list_test.csv | 4 +++- spec/models/user_spec.rb | 8 ++++---- 6 files changed, 19 insertions(+), 9 deletions(-) diff --git a/data/user_registration_list_development.csv b/data/user_registration_list_development.csv index 58aa06e0..c033ab55 100644 --- a/data/user_registration_list_development.csv +++ b/data/user_registration_list_development.csv @@ -46,7 +46,6 @@ aguess,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter bk5523,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cbrangwy,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cpena,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter -curt,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter dgraves,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter ekolemen,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter jakey,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter @@ -91,3 +90,6 @@ mfh2,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter mg9443,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter nc1514,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter sa3275,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter +dd7,,Dominique,Davis,Dominique Davis,,,,,TRUE,2024-12-10,Matt Chandler,TigerData Staff +hwcowles,,Wind,Cowles,Wind Cowles,TRUE,TRUE,,,TRUE,2024-12-19,Matt Chandler,TigerData Staff +curt,,Curt,Hillegas,Curt Hillegas,TRUE,,,TRUE,TRUE,2024-12-19,Matt Chandler,TigerData Staff diff --git a/data/user_registration_list_production.csv b/data/user_registration_list_production.csv index 58aa06e0..c033ab55 100644 --- a/data/user_registration_list_production.csv +++ b/data/user_registration_list_production.csv @@ -46,7 +46,6 @@ aguess,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter bk5523,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cbrangwy,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cpena,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter -curt,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter dgraves,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter ekolemen,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter jakey,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter @@ -91,3 +90,6 @@ mfh2,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter mg9443,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter nc1514,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter sa3275,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter +dd7,,Dominique,Davis,Dominique Davis,,,,,TRUE,2024-12-10,Matt Chandler,TigerData Staff +hwcowles,,Wind,Cowles,Wind Cowles,TRUE,TRUE,,,TRUE,2024-12-19,Matt Chandler,TigerData Staff +curt,,Curt,Hillegas,Curt Hillegas,TRUE,,,TRUE,TRUE,2024-12-19,Matt Chandler,TigerData Staff diff --git a/data/user_registration_list_qa.csv b/data/user_registration_list_qa.csv index 58aa06e0..c033ab55 100644 --- a/data/user_registration_list_qa.csv +++ b/data/user_registration_list_qa.csv @@ -46,7 +46,6 @@ aguess,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter bk5523,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cbrangwy,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cpena,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter -curt,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter dgraves,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter ekolemen,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter jakey,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter @@ -91,3 +90,6 @@ mfh2,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter mg9443,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter nc1514,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter sa3275,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter +dd7,,Dominique,Davis,Dominique Davis,,,,,TRUE,2024-12-10,Matt Chandler,TigerData Staff +hwcowles,,Wind,Cowles,Wind Cowles,TRUE,TRUE,,,TRUE,2024-12-19,Matt Chandler,TigerData Staff +curt,,Curt,Hillegas,Curt Hillegas,TRUE,,,TRUE,TRUE,2024-12-19,Matt Chandler,TigerData Staff diff --git a/data/user_registration_list_staging.csv b/data/user_registration_list_staging.csv index 58aa06e0..c033ab55 100644 --- a/data/user_registration_list_staging.csv +++ b/data/user_registration_list_staging.csv @@ -46,7 +46,6 @@ aguess,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter bk5523,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cbrangwy,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cpena,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter -curt,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter dgraves,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter ekolemen,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter jakey,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter @@ -91,3 +90,6 @@ mfh2,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter mg9443,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter nc1514,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter sa3275,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter +dd7,,Dominique,Davis,Dominique Davis,,,,,TRUE,2024-12-10,Matt Chandler,TigerData Staff +hwcowles,,Wind,Cowles,Wind Cowles,TRUE,TRUE,,,TRUE,2024-12-19,Matt Chandler,TigerData Staff +curt,,Curt,Hillegas,Curt Hillegas,TRUE,,,TRUE,TRUE,2024-12-19,Matt Chandler,TigerData Staff diff --git a/data/user_registration_list_test.csv b/data/user_registration_list_test.csv index 58aa06e0..c033ab55 100644 --- a/data/user_registration_list_test.csv +++ b/data/user_registration_list_test.csv @@ -46,7 +46,6 @@ aguess,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter bk5523,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cbrangwy,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter cpena,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter -curt,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter dgraves,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter ekolemen,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter jakey,,,,,TRUE,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter @@ -91,3 +90,6 @@ mfh2,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter mg9443,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter nc1514,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter sa3275,,,,,,,,,,2024-11-26,Matt Chandler,Capacity Early Adopter +dd7,,Dominique,Davis,Dominique Davis,,,,,TRUE,2024-12-10,Matt Chandler,TigerData Staff +hwcowles,,Wind,Cowles,Wind Cowles,TRUE,TRUE,,,TRUE,2024-12-19,Matt Chandler,TigerData Staff +curt,,Curt,Hillegas,Curt Hillegas,TRUE,,,TRUE,TRUE,2024-12-19,Matt Chandler,TigerData Staff diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index c903cb7b..1413fe77 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -87,26 +87,26 @@ it "creates a new user for every line in the file" do expect(User.count).to eq 0 User.load_registration_list - expect(User.count).to eq 92 + expect(User.count).to eq 94 end it "does not create a user if they exist already" do User.create(uid: "mjc12", family_name: "Chandler", display_name: "Matt Chandler", email: "mjc12@princeton.edu") expect(User.count).to eq 1 User.load_registration_list - expect(User.count).to eq 92 + expect(User.count).to eq 94 user = User.find_by(uid: "mjc12") # If we don't say that this is a cas user, they won't be able to log in with CAS expect(user.provider).to eq "cas" end it "updates a name if the name is updated in the spreadsheet" do User.load_registration_list - expect(User.count).to eq 92 + expect(User.count).to eq 94 blank_name_user = User.find_by(uid: "munan") expect(blank_name_user.family_name).to be_nil expect(blank_name_user.display_name).to be_nil allow(User).to receive(:csv_data).and_return(updated_csv_data) User.load_registration_list - expect(User.count).to eq 92 + expect(User.count).to eq 94 updated_name_user = User.find_by(uid: "munan") expect(updated_name_user.family_name).to eq "Nøme" expect(updated_name_user.display_name).to eq "Fáké Nøme"