changed: use std::filesystem instead of boost::filesystem
since we still support g++-7, where filesystem is marked experimental, we introduce a wrapper header and expose the namespace to use as Opm::filesystem. for gcc we unconditionally link with libstdc++fs in the python bindings. the setup.py stuff links as c code, not c++ code, so it is not automatically added on any gcc version. this might prove unportable later.
This commit is contained in:
@@ -23,7 +23,8 @@
|
||||
#include <boost/test/unit_test.hpp>
|
||||
#include <boost/test/test_tools.hpp>
|
||||
#include <boost/date_time/posix_time/posix_time.hpp>
|
||||
#include <boost/filesystem/path.hpp>
|
||||
|
||||
#include <opm/common/utility/FileSystem.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/Deck/DeckKeyword.hpp>
|
||||
@@ -40,7 +41,7 @@ inline std::string prefix() {
|
||||
|
||||
BOOST_AUTO_TEST_CASE(CreateCPGrid) {
|
||||
Parser parser;
|
||||
boost::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT.DATA");
|
||||
Opm::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT.DATA");
|
||||
auto deck = parser.parseFile(scheduleFile.string());
|
||||
EclipseState es(deck);
|
||||
const auto& grid = es.getInputGrid();
|
||||
@@ -54,7 +55,7 @@ BOOST_AUTO_TEST_CASE(CreateCPGrid) {
|
||||
|
||||
BOOST_AUTO_TEST_CASE(CreateCPActnumGrid) {
|
||||
Parser parser;
|
||||
boost::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT_ACTNUM.DATA");
|
||||
Opm::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT_ACTNUM.DATA");
|
||||
auto deck = parser.parseFile(scheduleFile.string());
|
||||
EclipseState es(deck);
|
||||
const auto& grid = es.getInputGrid();
|
||||
@@ -68,7 +69,7 @@ BOOST_AUTO_TEST_CASE(CreateCPActnumGrid) {
|
||||
|
||||
BOOST_AUTO_TEST_CASE(ExportFromCPGridAllActive) {
|
||||
Parser parser;
|
||||
boost::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT.DATA");
|
||||
Opm::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT.DATA");
|
||||
auto deck = parser.parseFile(scheduleFile.string());
|
||||
EclipseState es(deck);
|
||||
const auto& grid = es.getInputGrid();
|
||||
@@ -84,7 +85,7 @@ BOOST_AUTO_TEST_CASE(ExportFromCPGridAllActive) {
|
||||
|
||||
BOOST_AUTO_TEST_CASE(ExportFromCPGridACTNUM) {
|
||||
Parser parser;
|
||||
boost::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT_ACTNUM.DATA");
|
||||
Opm::filesystem::path scheduleFile(prefix() + "GRID/CORNERPOINT_ACTNUM.DATA");
|
||||
auto deck = parser.parseFile(scheduleFile.string());
|
||||
EclipseState es(deck);
|
||||
auto& grid = es.getInputGrid();
|
||||
|
||||
Reference in New Issue
Block a user