Re: Tests and Databases … and EOF re placements? Oh my!
Johann Werner <[email protected]>
| Newsgroups | gmane.comp.web.webobjects.wonder-disc |
|---|---|
| Message-ID | <[email protected]> |
Am 15.07.2012 um 02:42 schrieb Ray Kiddy: > > On Jul 14, 2012, at 3:39 PM, Johann Werner wrote: > >> That is a really good idea! To test at least parts of EOF would perhaps reveal some yet hidden bugs and define a known set of requirements an adaptor should support and thus making it easier to create new (working) adaptors. Also having the discussion of moving from EOF to a replacement tech X in mind that would provide some sort of requirement specification. >> >> Unfortunately I don't have any solution for your questions ready and time is quite tight at the moment. >> >> jw >> > > We always have more enthusiasm than time, no? ;-) At work they impatiently wait for cloning tech getting available ;-) But hey, I was just thinking aloud and though the discussion of moving to an EOF replacement is really interesting I myself have no project where EOF isn't doing a great job. But if there should be a serious work on a replacement then test would be a must, otherwise everyone would be in a sort of beta phase for the next couple of years... > I think the testing of EOF could reveal some bugs, but I would not over-estimate how many. Wonder has been going for quite a long time with a very small amount of public testability. From discussions on the lists, I think that some of the obvious people are probably doing a _lot_ of testing, but they cannot share the tests. A generous interpretation of why this is would be that the tests contain private data or code. So I think that Wonder is not as under-tested as it seems to be. If it was, frankly, it would have fallen apart a long time ago. > > But. It would be very helpful, IMHO, to have tests that we can all see. The WOWODC discussions of possible EOF replacements led straight to a discussion of how we would need tests to know if an EOF replacement would work. Which led to a whole bunch of people offering to write a bunch of tests. Or perhaps not. Did I just imagine that last part? :-) > > We will see. > > Some people may have felt there was a bit too much enthusiasm in the discussions at WOWODC for the whole "let's throw out this darn EOF thing and replace it" idea. Well, for one thing, as much fun as it was to talk of storming the castle, nobody grabbed a pitchfork that I saw. But it certainly was great to hear such a spirited discussion. We can certainly try some things and even entertain some silly suggestions. A new framework named after an obscure South American fruiting cactus? Sure! Create an example app and toss it in! But this was so much better than lethargy and despair. And even silly suggestions may turn into good ideas. It's happened before. > > cheers - ray > > >> Am 14.07.2012 um 19:55 schrieb Ray Kiddy: >> >>> >>> Hello - >>> >>> I am starting to poke at some of the tests, following up on some discussions we had at WOWODC. There _was_ a lot of discussion about testing, and some of it, amazingly, was not from me. >>> >>> I set up, quite a while back, a way to run the default Wonder tests against both the Memory adaptor and MySQL. The tests run against the Memory adaptor by default. For using MySQL, I add the following to my wobuild.properties: >>> >>> wo.test.dbAccess.adaptor=MySQL >>> wo.test.dbAccess.MySQL.URL=jdbc:mysql://localhost/wonderTest >>> wo.test.dbAccess.MySQL.name=ray >>> wo.test.dbAccess.MySQL.password=<password> >>> >>> >>> One can then just do: "ant tests.run" and … there are a lot of errors. >>> >>> Most of them seem to be about the fact that the tearDown methods in the tests have calls like "c1.delete()", where c1 is an instance of a Company EO, and the object is not actually deleted from the database. I am not sure why this is yet. This leads to odd test failures. For example, the tests of ERXEnterpriseObjectCache fail, because they assume some objects have unique names, and if objects do not get deleted, the names are not unique and the caching does odd things. And so on. >>> >>> Anyway. If anyone wants to grab an entrenching tool and start digging, please feel free. >>> >>> Also, there are questions I might figure out later, or not. >>> >>> For example, I need to find the right Properties magic for the ERXTest project to turn on log4j output when running the application via ant, which will probably lead to adding some log.debug() calls where they would be helpful. May need a special Listener? Or maybe I just need to set the properties in the right place. And I am sure there are other things. >>> >>> Would it not be cool, though, if one could type "ant tests.run" and run the entire set of tests against the Memory adaptor, an H2 database, MySQL, Postgres and FrontBase, all at once? I could have all these databases on my laptop and probably some more that I have forgotten. It _would_ be cool! >>> >>> - ray >> >> > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Wonder-disc mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/wonder-disc > ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/