It is possible to run test cases against a production server.
(Generally, we will not do that, but our customers might,
perhaps accidentally.) Try to write test cases in a way that
reduces the risk that running tests will alter or destroy
important tables, views, or other objects. (
DATABASE statements are particularly dangerous if
written using names that could exist on a customer's machine.)
To avoid such problems, you should use the following naming
User names: User names should begin with “mysql” (for example,
Database names: Unless you have a special reason not to, use the default database named
testthat is already created for you. For tests that need to operate outside the
testdatabase, database names should contain “test” or begin with “mysql” (for example,
For examples of how to name objects, examine the existing test cases. Of course, you can name columns and other objects inside tables as you wish.