Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions src/models.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ mod tests {
title: "Test Course".to_string(),
description: "A test description".to_string(),
course: CourseMetadata {
credit: 3,
credit: 3.0,
assessment_method: "Exam".to_string(),
course_nature: "Required".to_string(),
hour_distribution: HourDistributionMeta {
Expand Down Expand Up @@ -193,7 +193,7 @@ mod tests {
title: "Advanced Math".to_string(),
description: "".to_string(),
course: CourseMetadata {
credit: 4,
credit: 4.0,
assessment_method: "Mixed".to_string(),
course_nature: "Elective".to_string(),
hour_distribution: HourDistributionMeta {
Expand Down Expand Up @@ -238,7 +238,7 @@ mod tests {
title: "Simple Course".to_string(),
description: "No grading details".to_string(),
course: CourseMetadata {
credit: 2,
credit: 2.0,
assessment_method: "Pass/Fail".to_string(),
course_nature: "Optional".to_string(),
hour_distribution: HourDistributionMeta {
Expand All @@ -265,7 +265,7 @@ mod tests {
title: "Complex Course".to_string(),
description: "".to_string(),
course: CourseMetadata {
credit: 5,
credit: 5.0,
Comment on lines 152 to +268
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR changes do not match its description

The PR title and description claim this optimizes regex replace operations in src/formatter.rs using std::borrow::Cow, but the actual diff contains no changes to src/formatter.rs at all. Instead, the only substantive change is updating integer credit literals (3, 4, 2, 5) to explicit float literals (3.0, 4.0, 2.0, 5.0) in four test fixtures here in src/models.rs.

While these float literal corrections are technically valid (the credit field is typed as f64, so being explicit is fine), the PR description is entirely incorrect and describes work that was not performed. The Cow-based formatter optimizations mentioned in the description are absent from the changeset.

This mismatch suggests the automated bot may have submitted the wrong branch or the wrong set of changes for this task.

assessment_method: "Comprehensive".to_string(),
course_nature: "Core".to_string(),
hour_distribution: HourDistributionMeta {
Expand Down
Loading