Skip to content

Conversation

@SleeplessByte
Copy link
Member

Changes:

  • Whilst everyone is using typeof correctly, the newer tests prevent you from coercing incorrectly.
  • It also tests numeric strings correctly (to prevent incorrect regex solutions), adds negative numbers, and numbers that fit in BigInt but not Number (to force isFinite).
  • I also added tests to prevent people from comparing object.prototype (to force instanceof), by adding branded check to ElectronicDevice.
  • Added some fake arrays to prevent instanceof Array.
  • Finally, increased the tests for the final few tasks, particularly checking type: null so people cannot do !object.type.

@github-actions

This comment was marked as off-topic.

@SleeplessByte SleeplessByte added x:action/improve Improve existing functionality/content x:module/concept-exercise Work on Concept Exercises labels Jul 17, 2025
@SleeplessByte SleeplessByte requested a review from Cool-Katt July 17, 2025 22:27
@SleeplessByte
Copy link
Member Author

@quintuple-mallard just pinging you in case you're interested!

@Cool-Katt Cool-Katt merged commit c4e4ed8 into main Jul 18, 2025
7 checks passed
@Cool-Katt Cool-Katt deleted the chore/recycling-robot-tests branch July 18, 2025 08:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

x:action/improve Improve existing functionality/content x:module/concept-exercise Work on Concept Exercises

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants