summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBarry Warsaw2016-03-31 17:53:10 -0400
committerBarry Warsaw2016-03-31 18:22:32 -0400
commit011d278abcc25d417673f70a4eac0a8a78137d95 (patch)
treeb20f61ef24b61253bd09103282b81e39e7d0c371
parent3bc0f8a55400a4973ee9e391cb789f61361b90ca (diff)
downloadmailman-011d278abcc25d417673f70a4eac0a8a78137d95.tar.gz
mailman-011d278abcc25d417673f70a4eac0a8a78137d95.tar.zst
mailman-011d278abcc25d417673f70a4eac0a8a78137d95.zip
-rw-r--r--src/mailman/rest/tests/test_listconf.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mailman/rest/tests/test_listconf.py b/src/mailman/rest/tests/test_listconf.py
index 35bd516e0..eb39d7dea 100644
--- a/src/mailman/rest/tests/test_listconf.py
+++ b/src/mailman/rest/tests/test_listconf.py
@@ -410,3 +410,17 @@ class TestConfiguration(unittest.TestCase):
self.assertEqual(response.status, 204)
self.assertEqual(
self._mlist.goodbye_message_uri, 'mailman:///salutation.txt')
+
+ def test_advertised(self):
+ # GL issue #220 claimed advertised was read-only.
+ with transaction():
+ self._mlist.advertised = False
+ resource, response = call_api(
+ 'http://localhost:9001/3.0/lists/ant.example.com/config'
+ '/advertised')
+ self.assertFalse(resource['advertised'])
+ resource, response = call_api(
+ 'http://localhost:9001/3.0/lists/ant.example.com/config',
+ dict(advertised=True),
+ 'PATCH')
+ self.assertTrue(self._mlist.advertised)