Posted by marvil07 on June 21, 2009 at 6:04pm
I missed one WU, so what have been done since then:
- array access really helps to migrate to OOP, so each class implements that SPL interface
- Like it was expected, dia auto-generation only did the easy part, and like it's mentionen in WU2 I made a bulk update on each class trying map all needed functions as methods. After that I needed to make lots of manual changes, to use the methods and data members, but also fix the last ones to made relations between classes.
- I'm using references to the "parents" on "children", instead of lists of "children" on "parents" or both approaches (like item class repository data member instead of list of items on repository). This is not definitive, but now it's like this.
- Replace username on versioncontrol core in favor of author and commiter.
- Use already defined database identifier names instead of "id". This is mainly for use the cool drupal_write()
- New stuff working pushed on versioncontrol core oop branch, but like you imagine I needed a backend to test, so I used my own branch of git backend
- Repository add/edit/delete/fetch
- VCS Account add/list
Until now I've tried to avoid changing methods which I didn't use it in some known workflow(aka don't change without test)
So, what is left to finish OOP Version Control API?
This week target:
- follow sdboyer suggestions
- continue using git backend to do complete workflow
- Repository add/edit/delete/fetch
- VCS Account add/list
- ?
- commitlog working
- commit_restrictions? how to test?
- versioncontrol_account_status? how to test?
(help me here to define the list of what to test)
- after complete workflow, start implement interfaces and make it work with git backend

Comments
Tests, recap
In this week's IRC meeting, we agreed to defer further action on the OO-ification in favor of simpletests being written, so that tasks like the ones listed above (repository management, account management, etc.) can be tested and we can say with more confidence that stuff is still working.
Marco's task for the upcoming week is to create a minimal mock backend called versioncontrol_test (with hook_versioncontrol_backends() returning "test" as backend name) that enables repository and account management to work even though operations are not possible. Operation tests are assigned to Dan (dhax) who will come up with a set of commit scenarios and start to test those from the backends, starting with the Git backend and initially focusing on its hook scripts. Testing Commit Restrictions is part of operation testing, so please skip this one for now.
As for testing the Account Status module, there are a couple of use cases I can think of:
k, gotta go, maybe more on that some other time. Good luck, looking forward to your tests!