Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Alchemy Viewer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
Alchemy Viewer
Alchemy Viewer
Commits
997a5887
Commit
997a5887
authored
13 years ago
by
Logan Dethrow
Browse files
Options
Downloads
Patches
Plain Diff
Fixed linux exception catching macros in llevents_tut.cpp. All tests now pass on a lenny build
machine.
parent
51055b51
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
indra/test/llevents_tut.cpp
+5
-3
5 additions, 3 deletions
indra/test/llevents_tut.cpp
with
5 additions
and
3 deletions
indra/test/llevents_tut.cpp
+
5
−
3
View file @
997a5887
...
@@ -64,7 +64,7 @@ catch (const std::runtime_error& ex) \
...
@@ -64,7 +64,7 @@ catch (const std::runtime_error& ex) \
/* But if the expected exception was thrown, allow the test to */
\
/* But if the expected exception was thrown, allow the test to */
\
/* succeed anyway. Not sure how else to handle this odd case. */
\
/* succeed anyway. Not sure how else to handle this odd case. */
\
/* This approach is also used in llsdmessage_test.cpp. */
\
/* This approach is also used in llsdmessage_test.cpp. */
\
if (std::string(typeid(ex).name()) == typeid(
LLListenerOrPumpName::Empty
).name()) \
if (std::string(typeid(ex).name()) == typeid(
exception
).name())
\
{ \
{ \
threw = true; \
threw = true; \
} \
} \
...
@@ -87,9 +87,10 @@ catch (...) \
...
@@ -87,9 +87,10 @@ catch (...) \
catch (const std::runtime_error& ex) \
catch (const std::runtime_error& ex) \
{ \
{ \
std::cerr << "Failed to catch " << typeid(ex).name() << std::endl; \
std::cerr << "Failed to catch " << typeid(ex).name() << std::endl; \
if (std::string(typeid(ex).name()) == typeid(
LLListenerOrPumpName::Empty
).name()) \
if (std::string(typeid(ex).name()) == typeid(
exception
).name())
\
{ \
{ \
threw = ex.what(); \
threw = ex.what(); \
/*std::cout << ex.what() << std::endl;*/
\
} \
} \
else \
else \
{ \
{ \
...
@@ -455,7 +456,7 @@ void events_object::test<7>()
...
@@ -455,7 +456,7 @@ void events_object::test<7>()
threw
=
e
.
what
();
threw
=
e
.
what
();
// std::cout << "Caught: " << e.what() << '\n';
// std::cout << "Caught: " << e.what() << '\n';
}
}
CATCH_MISSED_LINUX_EXCEPTION_STRING
(
LLEventPump
::
Cycl
e
,
threw
)
CATCH_MISSED_LINUX_EXCEPTION_STRING
(
LLEventPump
::
OrderChang
e
,
threw
)
// Same remarks about the specific wording of the exception. Just
// Same remarks about the specific wording of the exception. Just
// ensure that it contains enough information to clarify the
// ensure that it contains enough information to clarify the
// problem and what must be done to resolve it.
// problem and what must be done to resolve it.
...
@@ -463,6 +464,7 @@ void events_object::test<7>()
...
@@ -463,6 +464,7 @@ void events_object::test<7>()
ensure_contains
(
"LLEventPump name"
,
threw
,
"'button'"
);
ensure_contains
(
"LLEventPump name"
,
threw
,
"'button'"
);
ensure_contains
(
"new listener name"
,
threw
,
"'of'"
);
ensure_contains
(
"new listener name"
,
threw
,
"'of'"
);
ensure_contains
(
"prev listener name"
,
threw
,
"'yellow'"
);
ensure_contains
(
"prev listener name"
,
threw
,
"'yellow'"
);
// std::cout << "Thrown Exception: " << threw << std::endl;
ensure_contains
(
"old order"
,
threw
,
"was: Mary, checked, yellow, shoelaces"
);
ensure_contains
(
"old order"
,
threw
,
"was: Mary, checked, yellow, shoelaces"
);
ensure_contains
(
"new order"
,
threw
,
"now: Mary, checked, shoelaces, of, yellow"
);
ensure_contains
(
"new order"
,
threw
,
"now: Mary, checked, shoelaces, of, yellow"
);
button
.
post
(
4
);
button
.
post
(
4
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment