Skip to content

fix resistance no longer parsing as number for types#665

Merged
seveibar merged 1 commit intomainfrom
resistance-fix
May 7, 2026
Merged

fix resistance no longer parsing as number for types#665
seveibar merged 1 commit intomainfrom
resistance-fix

Conversation

@seveibar
Copy link
Copy Markdown
Contributor

@seveibar seveibar commented May 7, 2026

No description provided.

@seveibar seveibar changed the title fix resistance no longer parsing as number fix resistance no longer parsing as number for types May 7, 2026
Comment thread tests/resistor.test.ts
Comment on lines +26 to +34
test("should parse resistance strings to numbers", () => {
const parsed = resistorProps.parse({
name: "R3",
resistance: "10k",
})

const parsedResistance: number = parsed.resistance
expect(parsedResistance).toBe(10000)
})
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The rule states that a *.test.ts file may have AT MOST one test(...) call; after that the tests must be split into multiple numbered files (e.g. resistor1.test.ts, resistor2.test.ts, etc.). This PR adds a second test(...) block ('should parse resistance strings to numbers') to tests/resistor.test.ts, which already contained at least one test(...) block before this change. Please move each test into its own numbered file to comply with the rule.

Spotted by Graphite (based on custom rule: Custom rule)

Fix in Graphite


Is this helpful? React 👍 or 👎 to let us know.

@seveibar seveibar merged commit 20330e9 into main May 7, 2026
5 checks passed
@tscircuitbot
Copy link
Copy Markdown
Contributor


Thank you for your contribution! 🎉

PR Rating: ⭐⭐
Impact: Minor

Track your contributions and see the leaderboard at: tscircuit Contribution Tracker


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