Fix a problem in StacktraceTests::BasicTests (#4069)

result.size() could be zero, in this case, we shouldn't access result[0]
This commit is contained in:
Changming Sun 2020-05-28 10:06:16 -07:00 committed by GitHub
parent a859dc422c
commit c94d9685b6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,9 +28,6 @@ TEST(StacktraceTests, BasicTests) {
// this method name should be the first on the stack as we hide the calls to the infrastructure that
// creates the stack trace
EXPECT_THAT(result[0], HasSubstr("BasicTests"));
else
// check that we have
EXPECT_THAT(result[0], HasSubstr("Unknown symbol"));
try {
ORT_THROW("Testing");