-
Notifications
You must be signed in to change notification settings - Fork 11
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 linguistics major and minor #454
Changes from 8 commits
1cf4c39
5d0b056
c002a9a
a52f89b
09281a0
d78fb13
b05c60e
3560a8c
d3b3126
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
import { Course, CollegeOrMajorRequirement } from '../../types'; | ||
|
||
import { | ||
courseIsFWS, | ||
ifCodeMatch, | ||
courseMatchesCodeOptions, | ||
includesWithSubRequirements, | ||
courseMeetsCreditMinimum, | ||
} from '../checkers-common'; | ||
|
||
const lingRequirements: readonly CollegeOrMajorRequirement[] = [ | ||
{ | ||
name: 'Foundation Courses', | ||
description: 'LING 1101, LING 3302, LING 3303, and LING 3314.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#major-requirements:', | ||
checker: includesWithSubRequirements( | ||
['LING 1101'], | ||
['LING 3302'], | ||
['LING 3303'], | ||
['LING 3314'] | ||
), | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1, 1, 1, 1], | ||
}, | ||
// TODO - change this into a compounded requirement instead of 3000, 2000, 1000+ electives. Works as expected right now though. | ||
{ | ||
name: 'Additional Courses: 3000 or above', | ||
description: | ||
'At least 2 additional linguistics courses must be at the 3000 level or above and at least 3 credits.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#major-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!(ifCodeMatch(course.catalogNbr, '1***') || ifCodeMatch(course.catalogNbr, '2***')) && | ||
!courseMatchesCodeOptions(course, ['LING 1101', 'LING 3302', 'LING 3303', 'LING 3314']) && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [2], | ||
}, | ||
{ | ||
name: 'Additional Courses: 2000 or above', | ||
description: | ||
'At least 3 additional linguistics courses must be 2000 level or above and at least 3 credits.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#major-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!ifCodeMatch(course.catalogNbr, '1***') && | ||
!courseMatchesCodeOptions(course, ['LING 1101', 'LING 3302', 'LING 3303', 'LING 3314']) && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [3], | ||
}, | ||
{ | ||
name: 'Additional Courses: 1000 or above', | ||
description: | ||
'At most 1 additional linguistics course can be 1000 level or above, but it must be at least 3 credits.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#major-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!courseMatchesCodeOptions(course, ['LING 1101', 'LING 3302', 'LING 3303', 'LING 3314']) && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
{ | ||
name: 'Ancillary Skills Courses', | ||
description: | ||
'Two courses (3 credits or more) must be in areas relevant to specific areas in linguistics.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#major-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
!courseMatchesCodeOptions(course, ['LING 1101', 'LING 3302', 'LING 3303', 'LING 3314']) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
checkerWarning: | ||
'We do not check that the courses are from linguistics related areas or 3+ credits.', | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [2], | ||
}, | ||
]; | ||
|
||
export default lingRequirements; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
import { Course, CollegeOrMajorRequirement } from '../../types'; | ||
|
||
import { | ||
courseIsFWS, | ||
ifCodeMatch, | ||
courseMatchesCodeOptions, | ||
includesWithSingleRequirement, | ||
courseMeetsCreditMinimum, | ||
} from '../checkers-common'; | ||
|
||
const lingMinorRequirements: readonly CollegeOrMajorRequirement[] = [ | ||
{ | ||
name: 'Introduction to Linguistics', | ||
description: 'LING 1101.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#minor-requirements:', | ||
checker: includesWithSingleRequirement('LING 1101'), | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
{ | ||
name: 'Foundation Course', | ||
description: 'LING 3302, LING 3303, or LING 3314.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#minor-requirements:', | ||
checker: includesWithSingleRequirement('LING 3302', 'LING 3303', 'LING 3314'), | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
// TODO - currently has a double counting issue because this is a minor with the foundation courses that can fulfill the elective courses, so they double count. | ||
// TODO - furthermore, this req is split into 3 and is a "compounded requirement." It works in the major right now, but in the minor | ||
// the double counting issue means one course can fulfill each part of the compounded requirement. | ||
{ | ||
name: 'Additional Course: 3000 or above', | ||
description: | ||
'At least 1 additional linguistics course must be at the 3000 level or above and at least 3 credits.', | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Do you want to add in the descriptions for the additional courses req that language courses cannot be used? There doesn't seem to be any indication in the descriptions currently. |
||
source: 'https://linguistics.cornell.edu/undergraduate#minor-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!(ifCodeMatch(course.catalogNbr, '1***') || ifCodeMatch(course.catalogNbr, '2***')) && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
{ | ||
name: 'Additional Course: 2000 or above', | ||
description: | ||
'At least 1 additional linguistics course must be 2000 level or above and at least 3 credits.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#minor-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!ifCodeMatch(course.catalogNbr, '1***') && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
{ | ||
name: 'Additional Course: 1000 or above', | ||
description: | ||
'At most 1 additional linguistics course can be 1000 level or above, but it must be at least 3 credits.', | ||
source: 'https://linguistics.cornell.edu/undergraduate#minor-requirements:', | ||
checker: [ | ||
(course: Course): boolean => | ||
ifCodeMatch(course.subject, 'LING') && | ||
!courseMatchesCodeOptions(course, ['LING 1101']) && | ||
!courseIsFWS(course) && | ||
courseMeetsCreditMinimum(course, 3), | ||
], | ||
fulfilledBy: 'courses', | ||
perSlotMinCount: [1], | ||
}, | ||
]; | ||
|
||
export default lingMinorRequirements; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we check that the courses are 3+ credits?