Skip to content

Add unit tests for api-tools/parser/gradeLoader #44#118

Open
SoggyRhino wants to merge 6 commits intoUTDNebula:feat-GradeLoaderTestsfrom
SoggyRhino:gradeloader
Open

Add unit tests for api-tools/parser/gradeLoader #44#118
SoggyRhino wants to merge 6 commits intoUTDNebula:feat-GradeLoaderTestsfrom
SoggyRhino:gradeloader

Conversation

@SoggyRhino
Copy link
Contributor

Since the profiles loader is going to be changed soon 111, this is just the unit tests for the grade loader.

gradeLoader

  • Changed api to return a map rather than setting the global value, this made it easier to test.
  • The biggest change here was to the logging originally we created a separate log file for each csv. I changed it so we just log normally (std out and single log file).
  • There was also a bug where the logging dir was hard coded to './logs/'

build.bat

  • Since build.bat is in the root directory we don't need to use ./... This was causing the script to run fmt in the parent directory (ie parent/api-tools), causing it to fail since I have other go projects there that are not formatted.

parser.go

  • Minor change due to the new api for load grades

parser_test.go

  • Updated tests to now use grade data
  • Made updater smarter so updating testcases doesn't make commits to bloated

validator_test.go

  • Made index map dynamic

@mikehquan19
Copy link
Contributor

@SoggyRhino when you have a chance, can you create a branch in main repo and redirect this PR?

@SoggyRhino SoggyRhino changed the base branch from develop to feat-GradeLoaderTests March 24, 2026 01:54
@mikehquan19 mikehquan19 self-requested a review March 27, 2026 04:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants