586586 u = UCPath ::User . new ( id )
587587 expect ( u . eligible? ) . to be ( false )
588588 end
589+
590+ it 'skips with zero Percentage of FullTime' do
591+ id = '10725310'
592+ stub_ucpath_user ( id )
593+ stub_ucpath_jobs ( id )
594+
595+ u = UCPath ::User . new ( id )
596+ expect ( u . eligible? ) . to be ( false )
597+ end
589598end
590599
591600describe UCPath ::Jobs do
@@ -603,7 +612,7 @@ def eligible(job)
603612 # Minimal structs to stand in for your “job” objects
604613 let ( :choose_job_struct ) { Struct . new ( :expected_end_date ) }
605614 let ( :eligible_job_struct ) do
606- Struct . new ( :hr_status_code , :expected_end_date , :org_relationship_code , :job_code , :percent_of_fulltime )
615+ Struct . new ( :hr_status_code , :expected_end_date , :org_relationship_code , :job_code , :percent_of_fulltime , :percent_of_fulltime_job )
607616 end
608617
609618 describe '#choose_job' do
@@ -652,55 +661,55 @@ def eligible(job)
652661 end
653662
654663 context "when hr_status_code is not 'A'" do
655- let ( :job ) { eligible_job_struct . new ( 'I' , '' , '' , 'ANY' , 1.0 ) }
664+ let ( :job ) { eligible_job_struct . new ( 'I' , '' , '' , 'ANY' , 1.0 , 0.0 ) }
656665
657666 it 'returns false' do
658667 expect ( eligible ( job ) ) . to be ( false )
659668 end
660669 end
661670
662671 context "when hr_status_code is 'A' and expected_end_date is blank" do
663- let ( :job ) { eligible_job_struct . new ( 'A' , '' , '' , 'ANY' , 1.0 ) }
672+ let ( :job ) { eligible_job_struct . new ( 'A' , '' , '' , 'ANY' , 1.0 , 0.0 ) }
664673
665674 it 'returns true' do
666675 expect ( eligible ( job ) ) . to be ( true )
667676 end
668677 end
669678
670679 context "when hr_status_code is 'A' and expected_end_date is after today" do
671- let ( :job ) { eligible_job_struct . new ( 'A' , '2026-03-01' , '' , 'ANY' , 1.0 ) }
680+ let ( :job ) { eligible_job_struct . new ( 'A' , '2026-03-01' , '' , 'ANY' , 1.0 , 0.0 ) }
672681
673682 it 'returns true' do
674683 expect ( eligible ( job ) ) . to be ( true )
675684 end
676685 end
677686
678687 context "when hr_status_code is 'A' and expected_end_date is today" do
679- let ( :job ) { eligible_job_struct . new ( 'A' , '2026-02-23' , '' , 'ANY' , 1.0 ) }
688+ let ( :job ) { eligible_job_struct . new ( 'A' , '2026-02-23' , '' , 'ANY' , 1.0 , 0.0 ) }
680689
681690 it 'returns false (<= today is not eligible per implementation)' do
682691 expect ( eligible ( job ) ) . to be ( false )
683692 end
684693 end
685694
686695 context "when hr_status_code is 'A' and expected_end_date is before today" do
687- let ( :job ) { eligible_job_struct . new ( 'A' , '2026-02-01' , '' , 'ANY' , 1.0 ) }
696+ let ( :job ) { eligible_job_struct . new ( 'A' , '2026-02-01' , '' , 'ANY' , 1.0 , 0.0 ) }
688697
689698 it 'returns false' do
690699 expect ( eligible ( job ) ) . to be ( false )
691700 end
692701 end
693702
694703 context 'when org_relationship_code is blank and other conditions pass' do
695- let ( :job ) { eligible_job_struct . new ( 'A' , '' , '' , 'ANY' , 1.0 ) }
704+ let ( :job ) { eligible_job_struct . new ( 'A' , '' , '' , 'ANY' , 1.0 , 0.0 ) }
696705
697706 it 'returns true' do
698707 expect ( eligible ( job ) ) . to be ( true )
699708 end
700709 end
701710
702711 context "when org_relationship_code is 'CWR' and job_code is NOT in either allowlist" do
703- let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'NOT_ALLOWED' , 1.0 ) }
712+ let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'NOT_ALLOWED' , 1.0 , 0.0 ) }
704713
705714 before do
706715 allow ( Config ) . to receive ( :check_ucpath_code )
@@ -718,7 +727,7 @@ def eligible(job)
718727 end
719728
720729 context "when org_relationship_code is 'CWR' and job_code IS in visiting_scholar_job_code" do
721- let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'ALLOWED' , 1.0 ) }
730+ let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'ALLOWED' , 1.0 , 0.0 ) }
722731
723732 before do
724733 allow ( Config ) . to receive ( :check_ucpath_code )
@@ -736,7 +745,7 @@ def eligible(job)
736745 end
737746
738747 context "when org_relationship_code is 'CWR' and job_code IS in ucb_academic_dept_affiliate_code" do
739- let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'ALLOWED' , 1.0 ) }
748+ let ( :job ) { eligible_job_struct . new ( 'A' , '' , 'CWR' , 'ALLOWED' , 1.0 , 0.0 ) }
740749
741750 before do
742751 allow ( Config ) . to receive ( :check_ucpath_code )
0 commit comments