Skip to content
This repository has been archived by the owner on Dec 11, 2020. It is now read-only.

Added Person Faker for en_PH #1463

Closed
wants to merge 1 commit into from
Closed

Conversation

jcfrane
Copy link

@jcfrane jcfrane commented Apr 10, 2018

No description provided.

@jcfrane
Copy link
Author

jcfrane commented Apr 10, 2018

Why the checks failed? I don't think the failures got something related on my commit.

@IngWARP
Copy link

IngWARP commented Apr 13, 2018

Check out the CONTRIBUTING.md
"Your code should follow the PSR-2 coding standard. Run make sniff to check that the coding standards are followed, and use php-cs-fixer to fix inconsistencies."

@Saibamen
Copy link
Contributor

@IngWARP: its not our fault.
See #1465

@Saibamen
Copy link
Contributor

@jcfrane Please close and reopen this pull request to build again

@jcfrane
Copy link
Author

jcfrane commented Jun 15, 2018

I will thanks.

@jcfrane jcfrane closed this Jun 16, 2018
@jcfrane jcfrane reopened this Jun 16, 2018
@jcfrane
Copy link
Author

jcfrane commented Jun 16, 2018

@Saibamen still failing... Some checks actually passed. Hmmmm.

@Saibamen
Copy link
Contributor

@jcfrane But now this is only your fault. See PHPUnit info:

1) Faker\Test\Provider\ProviderOverrideTest::testPerson with data set #19 ('en_PH')
InvalidArgumentException: Unknown formatter "suffix"

@jcfrane
Copy link
Author

jcfrane commented Jun 18, 2018

@Saibamen I see, Ok i'll fix this.

Copy link
Contributor

@ppelgrims ppelgrims left a comment

Choose a reason for hiding this comment

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

Nice work, almost there!

'Llorca', 'Panalangin', 'Dionisio', 'Cruz', 'Esteban', 'Santos', 'Aquino'
);

protected static $suffix = array('Jr.', 'Sr.', 'I', 'II', 'III', 'IV', 'V', 'MD', 'PhD', );
Copy link
Contributor

Choose a reason for hiding this comment

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

It's not enough to introduce a new format, you need to introduce a method as well. See src/Faker/Provider/Person.php, every static property has a corresponding (static) method. Some tests pass because the randomness doesn't always include the suffix format.

'Anthony', 'Allan',
'Ben', 'Buboy', 'Bobby', 'Bentong', 'Bayani',
'Cydrick', 'Carlo', 'Cardo', 'Cesar',
'JC', 'Mark Anthony', 'Jayfer', 'Paolo', 'Poy', 'Warren', 'Stephen', 'Maynard',
Copy link
Contributor

Choose a reason for hiding this comment

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

There is a double whitespace here.

'{{firstNameFemale}} {{lastName}}',
);

protected static $firstNameMale = array(
Copy link
Contributor

Choose a reason for hiding this comment

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

Please order this alphabetically.

'Michael', 'Jeric', 'Rex', 'Benigno'
);

protected static $firstNameFemale = array(
Copy link
Contributor

Choose a reason for hiding this comment

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

Please order this alphabetically. Lines should be 80 characters or less, this makes a diff easier to read, structure your code accordingly.

);

protected static $lastName = array(
'Frane', 'Rosario', 'Nonog', 'Balecha', 'Abendanio', 'Ramilio', 'Lacerna', 'Villanueva', 'Padilla',
Copy link
Contributor

Choose a reason for hiding this comment

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

Same comment as above

@jcfrane
Copy link
Author

jcfrane commented Jun 18, 2018

@ppelgrims i'll fix all your comments. Thanks for the guide :) My first time to actually contribute on open source.

@pimjansen
Copy link
Contributor

@jcfrane bump, could you please review again so we can find a way to get it merged?

@pimjansen
Copy link
Contributor

I am going to close this PR as stale. If this still needs to be merged, please feel free to reopen it.
Thanks for contributing

@pimjansen pimjansen closed this Oct 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants