Skip to content

Commit

Permalink
Fix exception unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gammasoft71 committed Sep 30, 2024
1 parent ec0d741 commit 4f6b06d
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions tests/xtd.core.unit_tests/src/xtd/tests/exception_tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ namespace xtd::tests {
assert::are_equal(0u, e.get_last_stack_frame().get_file_line_number(), csf_);
assert::is_empty(e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Exception of type 'xtd::exception' was thrown.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::is_empty(e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Exception of type 'xtd::exception' was thrown.", e.to_string(), csf_);
assert::are_equal("Exception of type 'xtd::exception' was thrown.", e.what(), csf_);
Expand All @@ -49,7 +49,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Exception of type 'xtd::exception' was thrown.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Exception of type 'xtd::exception' was thrown.\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("Exception of type 'xtd::exception' was thrown.", e.what(), csf_);
Expand All @@ -65,7 +65,7 @@ namespace xtd::tests {
assert::are_equal(0u, e.get_last_stack_frame().get_file_line_number(), csf_);
assert::is_empty(e.get_last_stack_frame().get_method(), csf_);
assert::is_empty(e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::is_empty(e.stack_trace(), csf_);
assert::are_equal("xtd::exception", e.to_string(), csf_);
assert::are_equal("xtd::exception", e.what(), csf_);
Expand All @@ -82,7 +82,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::is_empty(e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("xtd::exception", e.what(), csf_);
Expand All @@ -98,7 +98,7 @@ namespace xtd::tests {
assert::are_equal(0u, e.get_last_stack_frame().get_file_line_number(), csf_);
assert::is_empty(e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::is_empty(e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.", e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand All @@ -115,7 +115,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand All @@ -133,7 +133,7 @@ namespace xtd::tests {
assert::are_equal(0u, e.get_last_stack_frame().get_file_line_number(), csf_);
assert::is_empty(e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::is_empty(e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.", e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand All @@ -152,7 +152,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand All @@ -171,7 +171,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand All @@ -191,7 +191,7 @@ namespace xtd::tests {
assert::are_equal(stack_frame.get_file_line_number(), e.get_last_stack_frame().get_file_line_number(), csf_);
assert::are_equal(stack_frame.get_method(), e.get_last_stack_frame().get_method(), csf_);
assert::are_equal("Test excpetion message.", e.message(), csf_);
assert::are_equal("xtd::exception", e.name(), csf_);
assert::are_equal("xtd::exception", typeof_(e).full_name(), csf_);
assert::are_equal(stack_frame.to_string(), e.stack_trace(), csf_);
assert::are_equal("xtd::exception : Test excpetion message.\n" + stack_frame.to_string(), e.to_string(), csf_);
assert::are_equal("Test excpetion message.", e.what(), csf_);
Expand Down

0 comments on commit 4f6b06d

Please sign in to comment.