Hello community,
here is the log from the commit of package libstorage-ng for openSUSE:Factory checked in at 2018-02-14 09:17:48
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/libstorage-ng (Old)
and /work/SRC/openSUSE:Factory/.libstorage-ng.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libstorage-ng"
Wed Feb 14 09:17:48 2018 rev:8 rq:576226 version:3.3.158
Changes:
--------
--- /work/SRC/openSUSE:Factory/libstorage-ng/libstorage-ng.changes 2018-02-13 10:24:03.516648122 +0100
+++ /work/SRC/openSUSE:Factory/.libstorage-ng.new/libstorage-ng.changes 2018-02-14 09:17:58.025172565 +0100
@@ -1,0 +2,10 @@
+Tue Feb 13 12:30:35 UTC 2018 - aschnell@suse.de
+
+- merge gh#openSUSE/libstorage-ng#461
+- work on error handling
+- added documentation
+- coding style
+- extended test case
+- 3.3.158
+
+--------------------------------------------------------------------
Old:
----
libstorage-ng-3.3.157.tar.xz
New:
----
libstorage-ng-3.3.158.tar.xz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ libstorage-ng.spec ++++++
--- /var/tmp/diff_new_pack.LITFep/_old 2018-02-14 09:17:58.805144293 +0100
+++ /var/tmp/diff_new_pack.LITFep/_new 2018-02-14 09:17:58.813144003 +0100
@@ -18,7 +18,7 @@
%define libname %{name}1
Name: libstorage-ng
-Version: 3.3.157
+Version: 3.3.158
Release: 0
Summary: Library for storage management
License: GPL-2.0
++++++ libstorage-ng-3.3.157.tar.xz -> libstorage-ng-3.3.158.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/VERSION new/libstorage-ng-3.3.158/VERSION
--- old/libstorage-ng-3.3.157/VERSION 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/VERSION 2018-02-13 13:30:35.000000000 +0100
@@ -1 +1 @@
-3.3.157
+3.3.158
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/bindings/storage-catches.i new/libstorage-ng-3.3.158/bindings/storage-catches.i
--- old/libstorage-ng-3.3.157/bindings/storage-catches.i 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/bindings/storage-catches.i 2018-02-13 13:30:35.000000000 +0100
@@ -234,6 +234,9 @@
%catches(storage::Exception) storage::Storage::deactivate() const;
%catches(storage::Exception) storage::Storage::get_devicegraph(const std::string &name);
%catches(storage::Exception) storage::Storage::get_devicegraph(const std::string &name) const;
+%catches(storage::Exception) storage::Storage::get_probed() const;
+%catches(storage::Exception) storage::Storage::get_staging();
+%catches(storage::Exception) storage::Storage::get_staging() const;
%catches(storage::Exception) storage::Storage::probe();
%catches(storage::Exception) storage::Storage::remove_devicegraph(const std::string &name);
%catches(storage::Exception) storage::Storage::restore_devicegraph(const std::string &name);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/storage/Filesystems/MountPoint.h new/libstorage-ng-3.3.158/storage/Filesystems/MountPoint.h
--- old/libstorage-ng-3.3.157/storage/Filesystems/MountPoint.h 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/storage/Filesystems/MountPoint.h 2018-02-13 13:30:35.000000000 +0100
@@ -103,7 +103,14 @@
int get_passno() const;
+ /**
+ * Return whether the mount point is active (mounted).
+ */
bool is_active() const;
+
+ /**
+ * Sets whether the mount point is active (mounted).
+ */
void set_active(bool active);
/**
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/storage/Storage.cc new/libstorage-ng-3.3.158/storage/Storage.cc
--- old/libstorage-ng-3.3.157/storage/Storage.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/storage/Storage.cc 2018-02-13 13:30:35.000000000 +0100
@@ -216,7 +216,7 @@
CommitOptions commit_options(false);
commit(commit_options, commit_callbacks);
}
-
+
void
Storage::commit(const CommitOptions& commit_options, const CommitCallbacks* commit_callbacks)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/storage/Storage.h new/libstorage-ng-3.3.158/storage/Storage.h
--- old/libstorage-ng-3.3.157/storage/Storage.h 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/storage/Storage.h 2018-02-13 13:30:35.000000000 +0100
@@ -194,16 +194,22 @@
/**
* Return the staging devicegraph.
+ *
+ * @throw Exception
*/
Devicegraph* get_staging();
/**
* Return the staging devicegraph.
+ *
+ * @throw Exception
*/
const Devicegraph* get_staging() const;
/**
* Return the probed devicegraph.
+ *
+ * @throw Exception
*/
const Devicegraph* get_probed() const;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/storage/StorageImpl.cc new/libstorage-ng-3.3.158/storage/StorageImpl.cc
--- old/libstorage-ng-3.3.157/storage/StorageImpl.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/storage/StorageImpl.cc 2018-02-13 13:30:35.000000000 +0100
@@ -1,6 +1,6 @@
/*
* Copyright (c) [2014-2015] Novell, Inc.
- * Copyright (c) [2016-2017] SUSE LLC
+ * Copyright (c) [2016-2018] SUSE LLC
*
* All Rights Reserved.
*
@@ -213,11 +213,11 @@
Storage::Impl::get_devicegraph(const string& name)
{
if (name == "probed")
- ST_THROW(Exception("invalid name"));
+ ST_THROW(Exception(sformat("invalid devicegraph name '%s'", name.c_str())));
map::iterator it = devicegraphs.find(name);
if (it == devicegraphs.end())
- ST_THROW(Exception("device graph not found"));
+ ST_THROW(Exception(sformat("devicegraph '%s' not found", name.c_str())));
return &it->second;
}
@@ -228,7 +228,7 @@
{
map::const_iterator it = devicegraphs.find(name);
if (it == devicegraphs.end())
- ST_THROW(Exception("device graph not found"));
+ ST_THROW(Exception(sformat("devicegraph '%s' not found", name.c_str())));
return &it->second;
}
@@ -274,7 +274,7 @@
devicegraphs.emplace(piecewise_construct, forward_as_tuple(name),
forward_as_tuple(&storage));
if (!tmp.second)
- ST_THROW(Exception("device graph already exists"));
+ ST_THROW(Exception(sformat("devicegraph '%s' already exists", name.c_str())));
map::iterator it = tmp.first;
@@ -300,7 +300,7 @@
{
map::const_iterator it1 = devicegraphs.find(name);
if (it1 == devicegraphs.end())
- ST_THROW(Exception("device graph not found"));
+ ST_THROW(Exception(sformat("devicegraph '%s' not found", name.c_str())));
devicegraphs.erase(it1);
}
@@ -311,11 +311,11 @@
{
map::iterator it1 = devicegraphs.find(name);
if (it1 == devicegraphs.end())
- ST_THROW(Exception("device graph not found"));
+ ST_THROW(Exception(sformat("devicegraph '%s' not found", name.c_str())));
map::iterator it2 = devicegraphs.find("staging");
if (it2 == devicegraphs.end())
- ST_THROW(Exception("device graph not found"));
+ ST_THROW(Exception(sformat("devicegraph '%s' not found", name.c_str())));
it1->second.get_impl().swap(it2->second.get_impl());
devicegraphs.erase(it1);
@@ -366,8 +366,8 @@
stringstream tmp;
tmp << key_value.second;
- ST_THROW(Exception(sformat("objects with sid %d have different types %s", key_value.first,
- tmp.str().c_str())));
+ ST_THROW(Exception(sformat("objects with sid %d have different types %s",
+ key_value.first, tmp.str().c_str())));
}
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/Fixture.h new/libstorage-ng-3.3.158/testsuite/CompoundAction/Fixture.h
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/Fixture.h 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/Fixture.h 2018-02-13 13:30:35.000000000 +0100
@@ -31,7 +31,7 @@
Environment environment(true, ProbeMode::NONE, TargetMode::IMAGE);
storage = shared_ptr<Storage>(new Storage(environment));
staging = storage->get_staging();
-
+
auto sda = Disk::create(staging, "/dev/sda");
auto gpt = to_gpt(sda->create_partition_table(PtType::GPT));
sda1 = gpt->create_partition("/dev/sda1", Region(2048, 4 * 2048, 512), PartitionType::PRIMARY);
@@ -78,11 +78,10 @@
Partition* sda1;
Partition* sda2;
};
-
+
}
}
#endif
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/btrfs-subvolume-sentence.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/btrfs-subvolume-sentence.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/btrfs-subvolume-sentence.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/btrfs-subvolume-sentence.cc 2018-02-13 13:30:35.000000000 +0100
@@ -14,6 +14,7 @@
BOOST_FIXTURE_TEST_SUITE(btrfs_subvolume_sentence, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_sentence_on_creating)
{
initialize_staging_with_two_partitions();
@@ -23,9 +24,9 @@
auto subvolume = top_level_subvolume->create_btrfs_subvolume("test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, subvolume);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create subvolume test on /dev/sda2");
@@ -42,9 +43,9 @@
subvolume->set_nocow(true);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, subvolume);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create subvolume test on /dev/sda2 with option 'no copy on write'");
@@ -68,11 +69,11 @@
auto actiongraph = storage->calculate_actiongraph();
auto compound_action = find_compound_action_by_target(actiongraph, subvolume);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Delete subvolume @/tmp on /dev/sda2");
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/is-delete.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/is-delete.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/is-delete.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/is-delete.cc 2018-02-13 13:30:35.000000000 +0100
@@ -11,6 +11,7 @@
BOOST_FIXTURE_TEST_SUITE(is_delete, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_is_delete)
{
initialize_with_devicegraph("devicegraph.xml");
@@ -24,7 +25,7 @@
auto deleted_partition = Partition::find_by_name(storage->get_probed(), partition_name);
auto compound_action = find_compound_action_by_target(actiongraph, deleted_partition);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK(compound_action->is_delete());
@@ -38,11 +39,11 @@
auto actiongraph = storage->calculate_actiongraph();
auto compound_action = find_compound_action_by_target(actiongraph, sda1);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK(!compound_action->is_delete());
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/lvm-lv-sentence.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/lvm-lv-sentence.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/lvm-lv-sentence.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/lvm-lv-sentence.cc 2018-02-13 13:30:35.000000000 +0100
@@ -20,6 +20,7 @@
BOOST_FIXTURE_TEST_SUITE(lvm_lv_sentence, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_sentence_on_creating)
{
initialize_staging_with_two_partitions();
@@ -31,9 +32,9 @@
ext4->create_mount_point("/test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, lv);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create LVM logical volume /dev/vg-name/lv-name (10.00 GiB) on volume group vg-name for /test with ext4");
@@ -52,9 +53,9 @@
ext4->create_mount_point("/test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, lv);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create encrypted LVM logical volume /dev/vg-name/lv-name (10.00 GiB) on volume group vg-name for /test with ext4");
@@ -71,13 +72,13 @@
lv->create_blk_filesystem(FsType::SWAP);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, lv);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create LVM logical volume /dev/vg-name/lv-name (2.00 GiB) on volume group vg-name for swap");
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/lvm-vg-sentence.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/lvm-vg-sentence.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/lvm-vg-sentence.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/lvm-vg-sentence.cc 2018-02-13 13:30:35.000000000 +0100
@@ -12,6 +12,7 @@
BOOST_FIXTURE_TEST_SUITE(lvm_vg_sentence, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_sentence_on_creating)
{
initialize_staging_with_two_partitions();
@@ -20,13 +21,13 @@
vg->add_lvm_pv(sda2);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, vg);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create volume group vg-name (496.00 MiB) with /dev/sda2");
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/nfs-sentence.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/nfs-sentence.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/nfs-sentence.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/nfs-sentence.cc 2018-02-13 13:30:35.000000000 +0100
@@ -14,17 +14,18 @@
BOOST_FIXTURE_TEST_SUITE(nfs_sentence, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_sentence_on_creating)
{
initialize_staging_with_two_partitions();
- auto nfs = Nfs::create(staging, "192.168.0.1", "/dir");
+ auto nfs = Nfs::create(staging, "192.168.0.1", "/dir");
nfs->create_mount_point("/test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, nfs);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Mount NFS 192.168.0.1:/dir on /test");
@@ -39,8 +40,8 @@
nfs->remove_descendants();
auto actiongraph = storage->calculate_actiongraph();
-
auto probed_nfs = Nfs::get_all(storage->get_probed())[0];
+
auto compound_action = find_compound_action_by_target(actiongraph, probed_nfs);
BOOST_REQUIRE(compound_action);
@@ -48,5 +49,5 @@
BOOST_CHECK_EQUAL(compound_action->sentence(), "Unmount NFS 192.168.0.1:/dir at /test");
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/CompoundAction/partition-sentence.cc new/libstorage-ng-3.3.158/testsuite/CompoundAction/partition-sentence.cc
--- old/libstorage-ng-3.3.157/testsuite/CompoundAction/partition-sentence.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/CompoundAction/partition-sentence.cc 2018-02-13 13:30:35.000000000 +0100
@@ -17,6 +17,7 @@
BOOST_FIXTURE_TEST_SUITE(partition_sentence, test::CompoundActionFixture)
+
BOOST_AUTO_TEST_CASE(test_sentence_on_creating)
{
initialize_staging_with_two_partitions();
@@ -25,9 +26,9 @@
ext4->create_mount_point("/test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda2);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create partition /dev/sda2 (500.00 MiB) for /test with ext4");
@@ -44,9 +45,9 @@
ext4->create_mount_point("/test");
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda2);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create encrypted partition /dev/sda2 (500.00 MiB) for /test with ext4");
@@ -61,9 +62,9 @@
lvm_vg->add_lvm_pv(sda2);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda2);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create partition /dev/sda2 (500.00 MiB) as LVM physical volume");
@@ -80,9 +81,9 @@
lvm_vg->add_lvm_pv(encryption);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda2);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create encrypted partition /dev/sda2 (500.00 MiB) as LVM physical volume");
@@ -96,9 +97,9 @@
sda2->create_blk_filesystem(FsType::SWAP);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda2);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create partition /dev/sda2 (500.00 MiB) for swap");
@@ -112,9 +113,9 @@
sda1->set_id(ID_BIOS_BOOT);
auto actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, sda1);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Create partition /dev/sda1 (4.00 MiB) as BIOS Boot Partition");
@@ -131,9 +132,9 @@
fs->create_mount_point("/home");
const Actiongraph* actiongraph = storage->calculate_actiongraph();
-
+
auto compound_action = find_compound_action_by_target(actiongraph, partition);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Mount partition /dev/sda3 (42.27 GiB) at /home");
@@ -151,13 +152,13 @@
const Actiongraph* actiongraph = storage->calculate_actiongraph();
auto deleted_partition = Partition::find_by_name(storage->get_probed(), partition_name);
-
+
auto compound_action = find_compound_action_by_target(actiongraph, deleted_partition);
-
+
BOOST_REQUIRE(compound_action);
BOOST_CHECK_EQUAL(compound_action->sentence(), "Delete partition /dev/sda2 (28.50 GiB)");
}
-BOOST_AUTO_TEST_SUITE_END()
+BOOST_AUTO_TEST_SUITE_END()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-3.3.157/testsuite/Utils/humanstring.cc new/libstorage-ng-3.3.158/testsuite/Utils/humanstring.cc
--- old/libstorage-ng-3.3.157/testsuite/Utils/humanstring.cc 2018-02-12 18:05:00.000000000 +0100
+++ new/libstorage-ng-3.3.158/testsuite/Utils/humanstring.cc 2018-02-13 13:30:35.000000000 +0100
@@ -166,7 +166,12 @@
BOOST_AUTO_TEST_CASE(test_ridiculous_high_numbers)
{
- // The unshifted value fits 80-bit IEEE but the shifted value overflows.
+ // The unshifted value fits 64-bit IEEE but the shifted value
+ // overflows. Tests error handling if long double is 64-bit IEEE.
+ BOOST_CHECK_THROW(test("en_GB.UTF-8", "1.0E305 EiB", true), OverflowException);
+
+ // The unshifted value fits 80-bit IEEE but the shifted value
+ // overflows. Tests error handling if long double is 80-bit IEEE.
BOOST_CHECK_THROW(test("en_GB.UTF-8", "1.0E4930 EiB", true), OverflowException);
// Even the unshifted value is too high for 80-bit (and even 128-bit) IEEE.