Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pierre Fernbach
curves
Commits
1a68eb24
Commit
1a68eb24
authored
Aug 12, 2019
by
Pierre Fernbach
Browse files
[test] polynomial test : check if an error is correctly throw when tmin > tmax
parent
74a26ea7
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/Main.cpp
View file @
1a68eb24
...
...
@@ -1584,6 +1584,22 @@ void polynomialFromBoundaryConditions(bool& error){
error
=
true
;
std
::
cout
<<
"polynomialFromBoundaryConditions C2: curve is not degree 5 "
<<
std
::
endl
;
}
// check if the exeptions are correctly raised :
try
{
polynomial_t
polC0Err
=
polynomial_t
(
p0
,
p1
,
max
,
min
);
error
=
true
;
std
::
cout
<<
"Created a polynomial with tMin > tMax without error. "
<<
std
::
endl
;
}
catch
(
invalid_argument
e
){}
try
{
polynomial_t
polC1Err
=
polynomial_t
(
p0
,
dp0
,
p1
,
dp1
,
max
,
min
);
error
=
true
;
std
::
cout
<<
"Created a polynomial with tMin > tMax without error. "
<<
std
::
endl
;
}
catch
(
invalid_argument
e
){}
try
{
polynomial_t
polC2Err
=
polynomial_t
(
p0
,
dp0
,
ddp0
,
p1
,
dp1
,
ddp1
,
max
,
min
);
error
=
true
;
std
::
cout
<<
"Created a polynomial with tMin > tMax without error. "
<<
std
::
endl
;
}
catch
(
invalid_argument
e
){}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment