How to test accesors and mutators?
It's kind of interesting that I've had a hard time testing my classes to make sure its mutator and accesor methods work, quite simply because testing one requires the other and viceversa. I know that in test-driven development it is usually adviced to not test them because they are simple enough to be "trusted". However, when a member of my function is an array I feel uneasy about not testing the methods that are supposed to access and mutate it, since an array is no longer as simple as a variable. Then again my anxiety might just be typical in a newbie like me. I wonder though, if there is actually any method to test mutators, even if they are so intricately intertwined. They are quite simply supposed to be the only passageways of data in and out of the object. Should I just not test them? I definitely have always left out the possibility of making member variables public, even if just momentarily to test a mutator (for example) without having to use the accesor. I think it's not elegant, and not recomendable for continuous testing.
By the way I am programming in Visual Basic 6.0, something which I still find somewhat shameful, particularly because trying to do Object Oriented Programming is complicated :(
Thanks for the input!