(Some really old instructions copied from Glorp.org, which need updating. It's probably a clue how old when it refers to VisualWorks 5i)
Glorp gets its test login information from an SUnit test resource class called DatabaseLoginResource in the class (or shared in VW) variable called DefaultLogin. So I need to specify this login, which I can do by evaluating
GlorpDatabaseLoginResource defaultLogin: ((Login new) database: OraclePlatform new; username: 'System'; password: 'manager'; connectString: 'alan').
This tells GLORP the database that I'm logging into, my user name and password, and that it's an Oracle database.
Note for VisualWorks users: GlorpVWLauncherTool tool is available from cincomsmalltalk.com public store repository adding user interface to your launcher which allows easy login switching and changing various GLORP connection and testing options.
This is another test resource whose job is to create the initial database tables that GLORP will use. This is a fairly slow operation, and the tables don't change very often, so if we know this has already been done once for this database we skip it on subsequent test runs. If you think there's something wrong with your database setup, it's a good idea to run #invalidateSetup here to make sure that GLORP will completely destroy and recreate the tables next time it does a test run.
Note for VisualWorks users: You can conveniently check current status of this resource and reset it if nessecary from GlorpVWLauncherTool introduced earlier.
TestRunner new open (or if you're not in a workspace) XProgramming.SUnit.TestRunner new open
In VisualAge, it's
TestRunner new openWidgetand in Dolphin it's
TestRunner openOnce you have the test runner UI, click on the "Run" button. You should see the display go yellow and lots of test names flash past. Eventually, you'll see something like
172 tests run, 171 passed, 0 failed, 1 errorThe number of tests depends on the particular version. If you see all of the tests passed, then GLORP is working properly on your system. If you see failures, then you're going to need to figure out why, which is the tricky part. You'll need to look at the list of failures and run them in debug mode so that you can see what's going wrong.
Documentation is currently very limited. There is no user or reference manual. You can find some presentations and documentation of basic concepts, but the detailed information is still contained primarily in the code.
Fortunately, GLORP has a reasonably extensive test suite, and this is your best resource for finding out the details of features. If you want to know what a class or method does, look at the references or senders and see which tests might use this. This should give you quite a bit of information about how it's intended to be used (and what actually works :-)
mailing list. If you're working in VisualWorks 5 and later, you'll want to get an account on the cincomsmalltalk.com public store repository. The mailing lists are also the best way to get help on GLORP. The mailing list and the repository are the main ways GLORP is coordinated.
You can also join #smalltalk channel on Smalltalk IRC server at irc.parcplace.net, there's a pretty good chance someone there might be able to answer your questions or listen to feedback.
Last edited: Thursday, November 25, 2004