Index: /main/waeup.ikoba/trunk/src/waeup/ikoba/customers/tests/test_browser.py
===================================================================
--- /main/waeup.ikoba/trunk/src/waeup/ikoba/customers/tests/test_browser.py	(revision 12039)
+++ /main/waeup.ikoba/trunk/src/waeup/ikoba/customers/tests/test_browser.py	(revision 12040)
@@ -665,5 +665,5 @@
         self.assertTrue('An email with' in self.browser.contents)
 
-class CustomerRequestPWTests(CustomersFullSetup):
+class CustomerRegistrationTests(CustomersFullSetup):
     # Tests for customer registration
 
@@ -718,4 +718,28 @@
         return
 
+    def test_create_account(self):
+        # Customer with wrong number can't be found.
+        self.browser.open('http://localhost/app/createaccount')
+        self.browser.getControl(name="form.firstname").value = 'Ruben'
+        self.browser.getControl(name="form.lastname").value = 'Gonzales'
+        self.browser.getControl(name="form.email").value = 'newcustomer@xx.zz'
+        self.browser.getControl("Send login credentials").click()
+        self.assertTrue('Your request was successful.'
+            in self.browser.contents)
+        # ... and  customer can be found in the catalog via the email address
+        cat = queryUtility(ICatalog, name='customers_catalog')
+        results = list(
+            cat.searchResults(
+            email=('newcustomer@xx.zz', 'newcustomer@xx.zz')))
+        self.assertEqual(self.app['customers']['K1000001'], results[0])
+        self.assertEqual(self.app['customers']['K1000001'].firstname, 'Ruben')
+        self.assertEqual(self.app['customers']['K1000001'].lastname, 'Gonzales')
+        logfile = os.path.join(
+            self.app['datacenter'].storage, 'logs', 'main.log')
+        logcontent = open(logfile).read()
+        self.assertTrue('zope.anybody - customers.browser.CustomerCreateAccountPage - '
+                        'K1000001 - newcustomer@xx.zz' in logcontent)
+        return
+
 class CustomerDataExportTests(CustomersFullSetup, FunctionalAsyncTestCase):
     # Tests for CustomersContainer class views and pages
