/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/plugins/email/tests/testemail.py

  • Committer: Jelmer Vernooij
  • Date: 2018-07-15 18:45:17 UTC
  • mto: (7045.3.3 python3-r)
  • mto: This revision was merged to the branch mainline in revision 7047.
  • Revision ID: jelmer@jelmer.uk-20180715184517-1ipa50jg36zvglc5
Fix another 300 tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
136
136
        self.assertEqual(sender.url(), 'http://some.fake/url/')
137
137
 
138
138
    def test_public_url_set(self):
139
 
        config=("[DEFAULT]\n"
140
 
                "public_branch=http://the.publication/location/\n")
 
139
        config=(b"[DEFAULT]\n"
 
140
                b"public_branch=http://the.publication/location/\n")
141
141
        sender = self.get_sender(config)
142
142
        self.assertEqual(sender.url(), 'http://the.publication/location/')
143
143
 
144
144
    def test_url_precedence(self):
145
 
        config=("[DEFAULT]\n"
146
 
                "post_commit_url=http://some.fake/url/\n"
147
 
                "public_branch=http://the.publication/location/\n")
 
145
        config=(b"[DEFAULT]\n"
 
146
                b"post_commit_url=http://some.fake/url/\n"
 
147
                b"public_branch=http://the.publication/location/\n")
148
148
        sender = self.get_sender(config)
149
149
        self.assertEqual(sender.url(), 'http://some.fake/url/')
150
150
 
182
182
            timezone=0,
183
183
            committer="Sample <john@example.com>",
184
184
            )
185
 
        sender = EmailSender(self.branch, 'A', my_config)
 
185
        sender = EmailSender(self.branch, b'A', my_config)
186
186
        # This is usually only done after the EmailSender has locked the branch
187
187
        # and repository during send(), however, for testing, we need to do it
188
188
        # earlier, since send() is not called.