File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -87,8 +87,8 @@ def hr_data
8787 end
8888
8989 def campus_code_from_inst_role
90- umichinstrole = @data [ "umichinstroles" ] . first { |x | inst_role_base . match? ( x ) }
91- Patron . inst_role_map . first { |x | x [ "key" ] == umichinstrole } [ "campus" ]
90+ umichinstrole = @data [ "umichinstroles" ] . find { |x | x . match? ( inst_role_base ) }
91+ Patron . inst_role_map . find { |x | x [ "key" ] == umichinstrole } [ "campus" ]
9292 end
9393 end
9494end
Original file line number Diff line number Diff line change 1919 expect ( subject . campus_code ) . to eq ( "UMFL" )
2020 end
2121 it "comes from first faculty matched inst role when not hr data" do
22- @patron [ "umichinstroles" ] . push ( "FacultyAA" )
22+ @patron [ "umichinstroles" ] [ 1 ] = "FacultyDBRN"
2323 @patron [ "umichhr" ] = [ ]
24- expect ( subject . campus_code ) . to eq ( "UMAA " )
24+ expect ( subject . campus_code ) . to eq ( "UMDB " )
2525 end
2626 end
2727 context "#includable?" do
You can’t perform that action at this time.
0 commit comments