253
253
"preinstalled-headless"),
254
254
("daily-preinstalled", "ubuntu-server", "precise",
255
255
"preinstalled-server"),
256
("daily-preinstalled", "ubuntu-server", "xenial",
257
"preinstalled-server"),
256
258
("daily-preinstalled", "ubuntu", "precise",
257
259
"preinstalled-desktop"),
258
260
("daily-preinstalled", "ubuntu-touch", "saucy",
259
261
"preinstalled-touch"),
260
("daily-preinstalled", "ubuntu-pd", "vivid",
262
("daily-preinstalled", "ubuntu-touch-custom", "vivid",
263
"preinstalled-touch"),
262
264
("daily-live", "edubuntu", "edgy", "live"),
263
265
("daily-live", "edubuntu", "feisty", "desktop"),
264
266
("daily-live", "kubuntu-netbook", "lucid", "netbook"),
266
268
("daily-live", "ubuntu-mid", "lucid", "mid"),
267
269
("daily-live", "ubuntu-moblin-remix", "lucid", "moblin-remix"),
268
270
("daily-live", "ubuntu-netbook", "hardy", "netbook"),
269
("daily-live", "ubuntu-server", "hardy", "live"),
271
("daily-live", "ubuntu-server", "hardy", "live-server"),
270
272
("daily-live", "ubuntu", "breezy", "live"),
271
273
("daily-live", "ubuntu", "dapper", "desktop"),
272
274
("daily-live", "ubuntu-zh_CN", "raring", "desktop"),
275
("daily-live", "ubuntu-core", "xenial", "live-core"),
273
276
("ports_dvd", "ubuntu", "hardy", "dvd"),
274
277
("dvd", "kubuntu", "hardy", "dvd"),
275
278
("daily", "edubuntu", "edgy", "install"),
277
280
("daily", "edubuntu", "gutsy", "server"),
278
281
("daily", "edubuntu", "hardy", "addon"),
279
282
("daily", "jeos", "hardy", "jeos"),
280
("daily", "ubuntu-core", "precise", "core"),
283
("daily", "ubuntu-base", "precise", "base"),
281
284
("daily", "ubuntu-server", "breezy", "install"),
282
285
("daily", "ubuntu-server", "dapper", "server"),
283
286
("daily", "ubuntu", "breezy", "install"),
378
385
"For almost all PCs. This includes most machines with "
379
386
"Intel/AMD/etc type processors and almost all computers that run "
380
387
"Microsoft Windows, as well as newer Apple Macintosh systems "
381
"based on Intel processors. Choose this if you are at all "
388
"based on Intel processors.",
383
389
publisher.archdesc("i386", "desktop"))
392
"Choose this to take full advantage of computers based on the "
393
"AMD64 or EM64T architecture (e.g., Athlon64, Opteron, EM64T "
394
"Xeon, Core 2). If you have a non-64-bit processor made by AMD, "
395
"or if you need full support for 32-bit code, use the i386 images "
396
"instead. Choose this if you are at all unsure.",
397
publisher.archdesc("amd64", "desktop"))
385
399
def test_maybe_oversized(self):
386
400
self.config["DIST"] = "precise"
387
401
oversized_path = os.path.join(
677
691
def test_publish_base(self):
678
692
self.assertEqual(
694
self.config.root, "www", "full",
695
"ubuntu-server", "daily-preinstalled"),
696
self.make_publisher("ubuntu-server",
697
"daily-preinstalled").publish_base)
700
self.config.root, "www", "full", "ubuntu-core",
701
self.config.core_series, "edge"),
702
self.make_publisher("ubuntu-core", "daily-live").publish_base)
703
self.config["CHANNEL"] = 'stable'
706
self.config.root, "www", "full", "ubuntu-core",
707
self.config.core_series, "stable"),
708
self.make_publisher("ubuntu-core", "daily-live").publish_base)
680
711
self.config.root, "www", "full", "kubuntu", "daily-live"),
681
712
self.make_publisher("kubuntu", "daily-live").publish_base)
682
713
self.config["DIST"] = "hoary"
700
731
("ubuntustudio", None, "dvd", "i386", 4700372992),
701
732
("ubuntu-mid", None, "daily-live", "i386", 1073741824),
702
733
("ubuntu-moblin-remix", None, "daily-live", "i386", 1073741824),
703
("kubuntu", None, "daily-live", "i386", 1283457024),
704
("kubuntu-active", None, "daily-live", "i386", 1283457024),
705
("kubuntu-plasma5", None, "daily-live", "i386", 1283457024),
734
("kubuntu", "trusty", "daily-live", "i386", 1283457024),
735
("kubuntu", "xenial", "daily-live", "i386", 2000000000),
736
("kubuntu-active", "trusty", "daily-live", "i386", 1283457024),
737
("kubuntu-active", "xenial", "daily-live", "i386", 2000000000),
738
("kubuntu-plasma5", "trusty", "daily-live", "i386", 1283457024),
739
("kubuntu-plasma5", "xenial", "daily-live", "i386", 2000000000),
706
740
("ubuntu", None, "dvd", "i386", 4700372992),
707
741
("ubuntu", "precise", "daily-live", "i386", 736665600),
708
742
("ubuntu", "quantal", "daily-live", "i386", 801000000),
710
744
("ubuntu", "raring", "daily-live", "powerpc", 850000000),
711
745
("ubuntu", "saucy", "daily-live", "i386", 950000000),
712
746
("ubuntu", "saucy", "daily-live", "powerpc", 950000000),
713
("ubuntu", "trusty", "daily-live", "i386", 1073741824),
714
("ubuntu", "trusty", "daily-live", "powerpc", 1073741824),
747
("ubuntu", "trusty", "daily-live", "i386", 1200000000),
748
("ubuntu", "trusty", "daily-live", "powerpc", 1200000000),
749
("ubuntu", "xenial", "daily-live", "i386", 2000000000),
715
750
("xubuntu", "quantal", "daily-live", "i386", 736665600),
716
751
("xubuntu", "raring", "daily-live", "i386", 1073741824),
717
("xubuntu-base", None, "daily-live", "i386", 736665600),
752
("xubuntu", "xenial", "daily-live", "i386", 1460000000),
753
("xubuntu-base", "bionic", "daily-live", "i386", 736665600),
718
754
("ubuntu-gnome", "saucy", "daily-live", "i386", 1073741824),
719
("ubuntu-mate", None, "daily-live", "amd64", 1073741824),
755
("ubuntu-gnome", "xenial", "daily-live", "i386", 2000000000),
756
("ubuntu-budgie", "zesty", "daily-live", "i386", 2000000000),
757
("ubuntu-mate", "trusty", "daily-live", "amd64", 1073741824),
758
("ubuntu-mate", "xenial", "daily-live", "amd64", 2000000000),
759
("ubuntu-server", "xenial", "daily", "amd64", 1073741824),
760
("ubuntu-server", "zesty", "daily", "amd64", 736665600),
761
("ubuntu-server", "zesty", "daily", "ppc64el", 1073741824),
721
763
if dist is not None:
722
764
self.config["DIST"] = dist
865
907
target_dir, "%s-desktop-i386.iso.zsync" % self.config.series),
866
908
"%s-desktop-i386.iso" % self.config.series)
910
@mock.patch("cdimage.osextras.find_on_path", return_value=True)
911
@mock.patch("cdimage.tree.DailyTreePublisher.detect_image_extension",
912
return_value="img.xz")
913
@mock.patch("cdimage.tree.zsyncmake")
914
def test_publish_core_binary(self, mock_zsyncmake, *args):
915
self.config["DIST"] = "artful"
916
publisher = self.make_publisher("ubuntu-core", "daily-live")
917
source_dir = publisher.image_output("amd64")
919
source_dir, "%s-live-core-amd64.raw" % self.config.series))
922
"%s-live-core-amd64.model-assertion" % self.config.series))
923
self.capture_logging()
924
list(publisher.publish_binary("live-core", "amd64", "20170429"))
925
self.assertLogEqual([
926
"Publishing amd64 ...",
927
"Publishing amd64 model assertion ...",
928
"Making amd64 zsync metafile ...",
930
target_dir = os.path.join(publisher.publish_base, "20170429")
931
self.assertEqual([], os.listdir(source_dir))
932
self.assertCountEqual([
933
"ubuntu-core-16-amd64.img.xz",
934
"ubuntu-core-16-amd64.model-assertion",
935
], os.listdir(target_dir))
868
937
def test_publish_livecd_base(self):
869
938
publisher = self.make_publisher("livecd-base", "livecd-base")
870
939
source_dir = os.path.join(
958
1029
set(["raring-desktop-amd64.iso", "raring-desktop-i386.iso"]),
959
1030
publisher.published_images("20130321"))
1032
def test_published_core_images(self):
1033
self.config["DIST"] = "xenial"
1034
self.config["ARCHES"] = "amd64 i386"
1035
publisher = self.make_publisher("ubuntu-core", "daily-live")
1036
target_dir = os.path.join(publisher.publish_base, "20170429")
1039
"ubuntu-core-16-amd64.img.xz",
1040
"ubuntu-core-16-amd64.model-assertion",
1041
"ubuntu-core-16-i386.img.xz",
1042
"ubuntu-core-16-i386.model-assertion",
1044
touch(os.path.join(target_dir, name))
1046
set(["ubuntu-core-16-amd64.img.xz", "ubuntu-core-16-i386.img.xz"]),
1047
publisher.published_images("20170429"))
961
1049
@mock.patch("cdimage.tree.DailyTreePublisher.polish_directory")
962
1050
def test_mark_current_missing_to_single(self, mock_polish_directory):
963
1051
self.config["DIST"] = "raring"
1205
1293
("mythbuntu", "daily-live", "desktop", "Mythbuntu Desktop"),
1206
1294
("lubuntu", "daily", "alternate", "Lubuntu Alternate"),
1207
1295
("lubuntu", "daily-live", "desktop", "Lubuntu Desktop"),
1208
("ubuntu-core", "daily", "core", "Ubuntu Core"),
1296
("lubuntu-next", "daily-live", "desktop", "Lubuntu Next Desktop"),
1297
("ubuntu-base", "daily", "base", "Ubuntu Base"),
1209
1298
("ubuntukylin", "daily-live", "desktop", "Ubuntu Kylin Desktop"),
1210
1299
("ubuntu-gnome", "daily-live", "desktop", "Ubuntu GNOME Desktop"),
1211
("ubuntu-mate", "daily-live", "desktop", "Ubuntu Mate Desktop"),
1300
("ubuntu-budgie", "daily-live", "desktop",
1301
"Ubuntu Budgie Desktop"),
1302
("ubuntu-mate", "daily-live", "desktop", "Ubuntu MATE Desktop"),
1212
1303
("ubuntu-desktop-next", "daily-preinstalled",
1213
1304
"preinstalled-desktop-next", "Ubuntu Desktop (Unity 8)"),
1236
1327
"ubuntu-touch", "daily-preinstalled", "preinstalled-touch",
1330
def test_qa_product_ubuntu_touch_custom(self):
1331
publisher = self.make_publisher(
1332
"ubuntu-touch-custom", "daily-preinstalled")
1334
("Ubuntu Touch Custom armhf", "iso"),
1335
publisher.qa_product(
1336
"ubuntu-touch-custom", "daily-preinstalled",
1337
"preinstalled-touch", "armhf"))
1239
1339
def test_qa_product_ubuntu_preinstalled(self):
1240
1340
publisher = self.make_publisher("ubuntu", "daily")
1241
1341
self.assertEqual(
1267
1367
("mythbuntu", "daily-live", "desktop", "Mythbuntu Desktop"),
1268
1368
("lubuntu", "daily", "alternate", "Lubuntu Alternate"),
1269
1369
("lubuntu", "daily-live", "desktop", "Lubuntu Desktop"),
1270
("ubuntu-core", "daily", "core", "Ubuntu Core"),
1370
("lubuntu-next", "daily-live", "desktop", "Lubuntu Next Desktop"),
1371
("ubuntu-base", "daily", "base", "Ubuntu Base"),
1271
1372
("ubuntukylin", "daily-live", "desktop", "Ubuntu Kylin Desktop"),
1272
1373
("ubuntu-gnome", "daily-live", "desktop", "Ubuntu GNOME Desktop"),
1273
("ubuntu-mate", "daily-live", "desktop", "Ubuntu Mate Desktop"),
1374
("ubuntu-budgie", "daily-live", "desktop",
1375
"Ubuntu Budgie Desktop"),
1376
("ubuntu-mate", "daily-live", "desktop", "Ubuntu MATE Desktop"),
1274
1377
("ubuntu-desktop-next/system-image", "daily-preinstalled",
1275
1378
"preinstalled-desktop-next", "Ubuntu Desktop (Unity 8)"),
1901
2011
self.get_publisher().daily_dir(
1902
2012
"daily", "ubuntu-server/daily/20130327", "server"))
2015
self.temp_dir, "www", "full", "ubuntu-server",
2016
"daily-preinstalled", "20130327"),
2017
self.get_publisher().daily_dir(
2018
"daily-preinstalled",
2019
"ubuntu-server/daily-preinstalled/20130327", "server"))
1904
2021
def test_daily_dir_source(self):
1905
2022
self.config["PROJECT"] = "ubuntu"