Skip to content

Birmingham | 26-ITP-May | Gabriel Pawuoi | Sprint 2 | implement contains function and tests - #1406

Open
KhotKeys wants to merge 1 commit into
CodeYourFuture:mainfrom
KhotKeys:contains
Open

Birmingham | 26-ITP-May | Gabriel Pawuoi | Sprint 2 | implement contains function and tests#1406
KhotKeys wants to merge 1 commit into
CodeYourFuture:mainfrom
KhotKeys:contains

Conversation

@KhotKeys

@KhotKeys KhotKeys commented Aug 8, 2026

Copy link
Copy Markdown

Learners, PR Template

Self checklist

  • I have titled my PR with Region | Cohort | FirstName LastName | Sprint | Assignment Title
  • My changes meet the requirements of the task
  • I have tested my changes
  • My changes follow the style guide

Changelist

  • Implemented the contains function using hasOwnProperty to check if an object has a given property, with a type guard that returns false for non-objects and arrays.

  • Added tests covering an empty object, an existing property, a non-existent property, and an invalid input like an array.

@KhotKeys KhotKeys added 📅 Sprint 1 Assigned during Sprint 1 of this module Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. 📅 Sprint 2 Assigned during Sprint 2 of this module and removed 📅 Sprint 1 Assigned during Sprint 1 of this module labels Aug 8, 2026

@cjyuan cjyuan left a comment

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.

You have a newer and more complete Sprint-2 PR here: #1410

If this PR is no longer needed, please close it.

@cjyuan cjyuan removed the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Aug 10, 2026
@github-actions

Copy link
Copy Markdown

Your PR couldn't be matched to an assignment in this module.

Please check its title is in the correct format, and that you only have one PR per assignment.

If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed).

If this PR needs reviewed, please add the 'Needs Review' label to this PR after you have resolved the issues listed above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

📅 Sprint 2 Assigned during Sprint 2 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants