# Bazaar revision bundle v0.9 # # message: # Fix bug #92195. # # * tests/blackbox/test_merge_directive.py: # (TestMergeDirective.prepare_merge_directive): Set smtp_server in # branch config. # (TestMergeDirective.test_mail): Check that the smtp_server is # taken into account. # # * builtins.py: # (cmd_merge_directive.run): Provide config smtp_server to # SMTP.connect(). # # committer: Vincent Ladeuil # date: Wed 2007-03-14 11:37:18.571000099 +0100 === modified file NEWS --- NEWS +++ NEWS @@ -46,6 +46,9 @@ * Switch the ``bzr init-repo`` default from --no-trees to --trees. (Wouter van Heyst, #53483) + + * Take smtp_server from user config into account. + (vila, #92195) bzr 0.15rc1 2007-03-07 === modified file bzrlib/builtins.py --- bzrlib/builtins.py +++ bzrlib/builtins.py @@ -3410,7 +3410,7 @@ server = branch.get_config().get_user_option('smtp_server') if not server: server = 'localhost' - s.connect() + s.connect(server) s.sendmail(message['From'], message['To'], message.as_string()) === modified file bzrlib/tests/blackbox/test_merge_directive.py --- bzrlib/tests/blackbox/test_merge_directive.py +++ bzrlib/tests/blackbox/test_merge_directive.py @@ -40,6 +40,7 @@ self.build_tree_contents([('tree1/file', 'a\nb\nc\nd\n')]) tree1.branch.get_config().set_user_option('email', 'J. Random Hacker ') + tree1.branch.get_config().set_user_option('smtp_server', 'bogushost') tree1.add('file') tree1.commit('foo') tree2=tree1.bzrdir.sprout('tree2').open_workingtree() @@ -119,7 +120,7 @@ self.assertEqual('', md_text) self.assertEqual(1, len(connect_calls)) call = connect_calls[0] - self.assertEqual(('localhost', 0), call[1:3]) + self.assertEqual(('bogushost', 0), call[1:3]) self.assertEqual(1, len(sendmail_calls)) call = sendmail_calls[0] self.assertEqual(('J. Random Hacker ', === modified directory // last-changed:v.ladeuil+lp@free.fr-20070314103718-zg7 ... lmw9jc584l1xd # revision id: v.ladeuil+lp@free.fr-20070314103718-zg7lmw9jc584l1xd # sha1: 5e83941e8f5116e0296ab8eecdd4780bbe9bbca7 # inventory sha1: 98257a625eafd8a3e2dc7cfc150a6ac9e566d6bc # parent ids: # pqm@pqm.ubuntu.com-20070314050855-7241ac88a0577101 # base id: pqm@pqm.ubuntu.com-20070314050855-7241ac88a0577101 # properties: # branch-nick: 92195