Closed (fixed)
Project:
IMP
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
27 Oct 2013 at 03:09 UTC
Updated:
24 Nov 2013 at 05:00 UTC
Jump to comment: Most recent, Most recent file
Follow-up from #2118245: [meta] Source classes for config entities.
Write a D6 source plugin + tests for the profile_fields table.
| Comment | File | Size | Author |
|---|---|---|---|
| #10 | imp-created_source_profile_field-2121397-10.patch | 5.8 KB | fastangel |
| #8 | imp-created_source_profile_field-2121397-7.patch | 5.58 KB | fastangel |
Comments
Comment #1
fastangel commentedI created a first version. Attach the patch.
I have a little question about test. Which should be the test cases?
Comment #2
chx commentedWe usually just cook up random things; the content doesn't matter much -- especially in a simple case like this. However, as the work progresses and we discover this or that source plugin actually needs a bit more logic it's better to have a simple test written already.
Comment #3
fastangel commentedSound good. I added a three simple cases that should be enough at the moment.
Comment #4
marvil07 commentedStill some minor fixes to do:
adding visibility as public here
should be fid, right?
Comment #5
fastangel commentedFixed. One little comment. I check the rest of classes and I saw that don't have public visibility. Should open a new issue to fix?
Comment #6
chx commented->select('profile_fields', 'pf')
+ $this->databaseContents['profilefield'] = $this->results;
Please fix the table name in the latter to be profile_fields. I hope the test didn't pass in this state...
Comment #7
fastangel commentedOhh sorry. I attach new version.
Comment #8
fastangel commentedSorry.
Comment #9
marvil07 commentedPlease inherit now from Drupal6SqlBase class.
Also, please implement RequirementsInterface, so the same check on profile values source is here, an example of use on Comment source.
Comment #10
fastangel commentedUpdated
Comment #11
chx commentedI have committed this. Both of needs to improve here: I need to attend to your patches much faster, sorry for letting them linger. In turn, I would appreciate if you could run your tests before submitting them -- this one included two syntax errors.
Comment #12
fastangel commentedOk and sory about the bug of syntaxis. I forgot to execute test.