docs: def replace(self, messages, domain='messages'):
          """
          Sets translations for a given domain.
          """
          assert isinstance(messages, (dict, CaseInsensitiveDict))
          assert isinstance(domain, (str, unicode))
  
          self.messages[domain] = CaseInsensitiveDict({})
          self.add(messages, domain)