From: Warren Young Date: October 27 2008 8:58pm Subject: Re: Patch for ssqls null blob deficiency List-Archive: http://lists.mysql.com/plusplus/8074 Message-Id: <49062B66.1010005@etr-usa.com> MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Russell Robinson wrote: > > Warren pointed out that Null is not a transparent wrapper, > however, the SSQLS code works fine for all types, including Text, except > Blobs. I didn't mean to imply that this can't or shouldn't be fixed. I was just pointing out why it doesn't work *yet*. To make Null<> truly transparent, we need to add a lot of wrappers to it to call functions of the same name on the underlying data object. I've added a Wishlist item to do this at least for the std::string interface. > I've followed the instructions from SVN in HACKERS.txt. Yes, and beautifully so. I wish all patches I received were this clean. This fix will appear in v3.0.7. > I've created a 12th unit test which won't compile without the patch being > applied. WIth the patch applied, the new unit test compiles and executes OK. test/* is for individual unit tests, which don't need to access the DB. Anything that needs to access the DB or exercises multiple units acting in concert goes in examples/*. (This is really just a single criterion: anything that accesses the DB necessarily tests multiple units at once.) You can think of examples/* as integration tests. I'll put this in HACKERS.txt. If you did want a unit test for this, it should look like test/string.cpp: just test data integrity of an SSQLS in the face of construction, assignment, and data conversion. What your test did is better done as modifications to load_jpeg and cgi_jpeg, which I've done. You might look the new versions over to see that they're testing what you need them to. > There are no changes to the bmark.txt output - it doesn't count the number of > unit tests or their output, apparently. Right. test/* is supposed to run silently on success. This is another difference between it and examples/*.