Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skipif fix #821

Merged
merged 5 commits into from
Jul 27, 2018
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions test/functional/pdo_sqlsrv/skipif_version_less_than_2k14.inc
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ if (!$is_win) {
if ($msodbcsql_maj < 17 or $msodbcsql_min < 2) {
die("skip Unsupported ODBC driver version");
}
} else {
if ($msodbcsql_maj < 17) {
die("skip Unsupported ODBC driver version");
}
}

// Get SQL Server Version
Expand Down
4 changes: 4 additions & 0 deletions test/functional/sqlsrv/skipif_version_less_than_2k14.inc
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ if (!$is_win) {
if ($msodbcsql_maj < 17 or $msodbcsql_min < 2) {
die("skip Unsupported ODBC driver version");
}
} else {
if ($msodbcsql_maj < 17) {
die("skip Unsupported ODBC driver version");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is the else clause still necessary?

}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: change this to

if (!$is_win) {
    if ($msodbcsql_maj < 17) {
        die("skip Unsupported ODBC driver version");
    } else {
       // $msodbcsql_maj >= 17
       if ($msodbcsql_maj == 17 && $msodbcsql_min < 2 ) {
         die...
       } 
    }
} 

}

// Get SQL Server version
Expand Down