Updated to use ParseMode.
This commit is contained in:
parent
6ea7677a59
commit
7b6172a1f8
|
@ -30,6 +30,7 @@
|
|||
#include <opm/core/props/BlackoilPropertiesFromDeck.hpp>
|
||||
#include <opm/core/simulator/BlackoilState.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
|
@ -84,9 +85,10 @@ try
|
|||
parameter::ParameterGroup param(argc, argv);
|
||||
std::cout << "--------------- Reading parameters ---------------" << std::endl;
|
||||
const std::string deck_filename = param.get<std::string>("deck_filename");
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile(deck_filename);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::DeckConstPtr deck = parser->parseFile(deck_filename , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck, parseMode));
|
||||
const double grav = param.getDefault("gravity", unit::gravity);
|
||||
GridManager gm(deck);
|
||||
const UnstructuredGrid& grid = *gm.c_grid();
|
||||
|
|
|
@ -44,6 +44,7 @@
|
|||
#include <opm/core/flowdiagnostics/TofDiscGalReorder.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
|
||||
#include <memory>
|
||||
|
@ -166,8 +167,9 @@ try
|
|||
// Read the deck.
|
||||
std::string deck_filename = param.get<std::string>("deck_filename");
|
||||
Parser parser;
|
||||
DeckConstPtr deck = parser.parseFile(deck_filename);
|
||||
EclipseStateConstPtr eclipseState = std::make_shared<EclipseState>(deck);
|
||||
ParseMode parseMode;
|
||||
DeckConstPtr deck = parser.parseFile(deck_filename , parseMode);
|
||||
EclipseStateConstPtr eclipseState = std::make_shared<EclipseState>(deck , parseMode);
|
||||
|
||||
// Grid init
|
||||
GridManager grid_manager(deck);
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "config.h"
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#include <iostream>
|
||||
|
@ -361,7 +362,8 @@ int main(int argc, char** argv)
|
|||
// Parse grdecl file
|
||||
std::cout << "Parsing grid file '" << eclipsefilename << "' ..." << std::endl;
|
||||
Opm::ParserPtr parser(new Opm::Parser);
|
||||
Opm::DeckConstPtr deck(parser->parseFile(eclipsefilename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(eclipsefilename , parseMode));
|
||||
if ( ! (deck->hasKeyword("SPECGRID") && deck->hasKeyword("COORD") && deck->hasKeyword("ZCORN")) ) {
|
||||
std::cerr << "Grid file " << eclipsefilename << "are missing keywords SPECGRID, COORD or ZCORN!" << std::endl;
|
||||
exit(1);
|
||||
|
|
|
@ -45,6 +45,7 @@
|
|||
#include <opm/core/simulator/SimulatorCompressibleTwophase.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||
|
||||
|
||||
|
@ -97,9 +98,10 @@ try
|
|||
// int max_well_control_iterations = 0;
|
||||
double gravity[3] = { 0.0 };
|
||||
if (use_deck) {
|
||||
ParseMode parseMode;
|
||||
std::string deck_filename = param.get<std::string>("deck_filename");
|
||||
deck = parser->parseFile(deck_filename);
|
||||
eclipseState.reset(new EclipseState(deck));
|
||||
deck = parser->parseFile(deck_filename , parseMode);
|
||||
eclipseState.reset(new EclipseState(deck, parseMode));
|
||||
|
||||
// Grid init
|
||||
grid.reset(new GridManager(deck));
|
||||
|
|
|
@ -110,10 +110,11 @@ try
|
|||
double gravity[3] = { 0.0 };
|
||||
if (use_deck) {
|
||||
ParserPtr parser(new Opm::Parser());
|
||||
ParseMode parseMode;
|
||||
|
||||
std::string deck_filename = param.get<std::string>("deck_filename");
|
||||
deck = parser->parseFile(deck_filename);
|
||||
eclipseState.reset( new EclipseState(deck));
|
||||
deck = parser->parseFile(deck_filename , parseMode);
|
||||
eclipseState.reset( new EclipseState(deck, parseMode));
|
||||
// Grid init
|
||||
grid.reset(new GridManager(deck));
|
||||
// Rock and fluid init
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include <opm/core/linalg/LinearSolverFactory.hpp>
|
||||
#include <opm/core/props/rock/RockCompressibility.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
|
@ -34,9 +35,10 @@ try
|
|||
simtimer.init(parameters);
|
||||
|
||||
// Read input file
|
||||
ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck = parser->parseFile(file_name);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::DeckConstPtr deck = parser->parseFile(file_name , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
std::cout << "Done!" << std::endl;
|
||||
|
||||
// Setup grid
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
|
||||
#include <opm/core/utility/parameters/ParameterGroup.hpp>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Units/UnitSystem.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/Deck/DeckKeyword.hpp>
|
||||
|
@ -44,8 +45,9 @@ namespace Opm
|
|||
public:
|
||||
CornerPointChopper(const std::string& file)
|
||||
{
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
deck_ = parser->parseFile(file);
|
||||
deck_ = parser->parseFile(file , parseMode);
|
||||
|
||||
metricUnits_.reset(Opm::UnitSystem::newMETRIC());
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ WELLDIMS
|
|||
ENDSCALE
|
||||
--DIR REV NTENDP NSENDP
|
||||
'NODIR' 'REVERS' 1 20 /
|
||||
/
|
||||
|
||||
|
||||
START
|
||||
1 'JAN' 1990 /
|
||||
|
|
|
@ -21,7 +21,7 @@ WELLDIMS
|
|||
ENDSCALE
|
||||
--DIR REV NTENDP NSENDP
|
||||
'NODIR' 'REVERS' 1 20 /
|
||||
/
|
||||
|
||||
|
||||
START
|
||||
1 'JAN' 1990 /
|
||||
|
|
|
@ -21,7 +21,7 @@ WELLDIMS
|
|||
ENDSCALE
|
||||
--DIR REV NTENDP NSENDP
|
||||
'NODIR' 'REVERS' 1 20 /
|
||||
/
|
||||
|
||||
|
||||
START
|
||||
1 'JAN' 1990 /
|
||||
|
|
|
@ -21,7 +21,7 @@ WELLDIMS
|
|||
ENDSCALE
|
||||
--DIR REV NTENDP NSENDP
|
||||
'NODIR' 'REVERS' 1 20 /
|
||||
/
|
||||
|
||||
|
||||
START
|
||||
1 'JAN' 1990 /
|
||||
|
|
|
@ -21,7 +21,7 @@ WELLDIMS
|
|||
ENDSCALE
|
||||
--DIR REV NTENDP NSENDP
|
||||
'NODIR' 'REVERS' 1 20 /
|
||||
/
|
||||
|
||||
|
||||
SATOPTS
|
||||
HYSTER /
|
||||
|
|
|
@ -29,7 +29,7 @@ DZV
|
|||
|
||||
DEPTHZ
|
||||
121*1000 /
|
||||
/
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
#include <opm/core/props/phaseUsageFromDeck.hpp>
|
||||
#include <opm/core/utility/parameters/ParameterGroup.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
|
@ -91,7 +92,7 @@ void verifyRFTFile(const std::string& rft_filename) {
|
|||
|
||||
Opm::DeckConstPtr createDeck(const std::string& input_str) {
|
||||
Opm::ParserPtr parser = std::make_shared<Opm::Parser>();
|
||||
Opm::DeckConstPtr deck = parser->parseString(input_str);
|
||||
Opm::DeckConstPtr deck = parser->parseString(input_str , Opm::ParseMode());
|
||||
return deck;
|
||||
}
|
||||
|
||||
|
@ -201,7 +202,7 @@ BOOST_AUTO_TEST_CASE(test_EclipseWriterRFTHandler)
|
|||
test_area.reset(new_ptr, test_work_area_free);
|
||||
|
||||
std::shared_ptr<const Opm::Deck> deck = createDeck(deckString);
|
||||
std::shared_ptr<Opm::EclipseState> eclipseState = std::make_shared<Opm::EclipseState>(deck);
|
||||
std::shared_ptr<Opm::EclipseState> eclipseState = std::make_shared<Opm::EclipseState>(deck , Opm::ParseMode());
|
||||
|
||||
std::shared_ptr<Opm::SimulatorTimer> simulatorTimer = std::make_shared<Opm::SimulatorTimer>();
|
||||
simulatorTimer->init(eclipseState->getSchedule()->getTimeMap());
|
||||
|
|
|
@ -55,13 +55,14 @@ std::shared_ptr<Opm::WellState> wellState;
|
|||
|
||||
void createEclipseWriter(const char *deckString)
|
||||
{
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserConstPtr parser(new Opm::Parser());
|
||||
deck = parser->parseString(deckString);
|
||||
deck = parser->parseString(deckString, parseMode);
|
||||
|
||||
Opm::parameter::ParameterGroup params;
|
||||
params.insertParameter("deck_filename", "foo.data");
|
||||
|
||||
eclipseState.reset(new Opm::EclipseState(deck));
|
||||
eclipseState.reset(new Opm::EclipseState(deck , parseMode));
|
||||
|
||||
auto eclGrid = eclipseState->getEclipseGrid();
|
||||
BOOST_CHECK(eclGrid->getNX() == 3);
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
#include <opm/core/utility/ErrorMacros.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||
|
||||
|
@ -233,8 +234,9 @@ BOOST_AUTO_TEST_CASE(test_liveoil)
|
|||
const std::string filename = "liveoil.DATA";
|
||||
cout << "Reading deck: " << filename << endl;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::EclipseStateConstPtr eclipseState(new EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
Opm::EclipseStateConstPtr eclipseState(new EclipseState(deck, parseMode));
|
||||
|
||||
// setup pvt interface
|
||||
PhaseUsage phase_usage_ = phaseUsageFromDeck(deck);
|
||||
|
@ -313,8 +315,9 @@ BOOST_AUTO_TEST_CASE(test_wetgas)
|
|||
const std::string filename = "wetgas.DATA";
|
||||
cout << "Reading deck: " << filename << endl;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::EclipseStateConstPtr eclipseState(new EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
Opm::EclipseStateConstPtr eclipseState(new EclipseState(deck, parseMode));
|
||||
|
||||
// setup pvt interface
|
||||
PhaseUsage phase_usage_ = phaseUsageFromDeck(deck);
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
#include <opm/core/props/BlackoilPhases.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#if HAVE_DYNAMIC_BOOST_TEST
|
||||
|
@ -29,11 +30,12 @@ using namespace std;
|
|||
|
||||
BOOST_AUTO_TEST_CASE(EqualsDifferentDeckReturnFalse) {
|
||||
|
||||
ParseMode parseMode;
|
||||
const string filename1 = "testBlackoilState1.DATA";
|
||||
const string filename2 = "testBlackoilState2.DATA";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck1(parser->parseFile(filename1));
|
||||
Opm::DeckConstPtr deck2(parser->parseFile(filename2));
|
||||
Opm::DeckConstPtr deck1(parser->parseFile(filename1, parseMode));
|
||||
Opm::DeckConstPtr deck2(parser->parseFile(filename2, parseMode));
|
||||
|
||||
GridManager gridManager1(deck1);
|
||||
const UnstructuredGrid* grid1 = gridManager1.c_grid();
|
||||
|
@ -54,8 +56,9 @@ BOOST_AUTO_TEST_CASE(EqualsDifferentDeckReturnFalse) {
|
|||
BOOST_AUTO_TEST_CASE(EqualsDifferentNumPhasesReturnFalse) {
|
||||
|
||||
const string filename = "testBlackoilState1.DATA";
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename, parseMode));
|
||||
|
||||
GridManager gridManager(deck);
|
||||
const UnstructuredGrid* grid = gridManager.c_grid();
|
||||
|
@ -74,8 +77,9 @@ BOOST_AUTO_TEST_CASE(EqualsDifferentNumPhasesReturnFalse) {
|
|||
BOOST_AUTO_TEST_CASE(EqualsNumericalDifferenceReturnFalse) {
|
||||
|
||||
const string filename = "testBlackoilState1.DATA";
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
GridManager gridManager(deck);
|
||||
const UnstructuredGrid* grid = gridManager.c_grid();
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
#include <opm/core/grid/GridManager.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#include <cstddef>
|
||||
|
@ -130,9 +131,9 @@ BOOST_AUTO_TEST_CASE(DisjointColumn)
|
|||
correct_answer[4].resize(1);
|
||||
correct_answer[9].resize(1);
|
||||
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseString(grdecl));
|
||||
|
||||
Opm::DeckConstPtr deck(parser->parseString(grdecl , parseMode));
|
||||
Opm::GridManager manager(deck);
|
||||
|
||||
VVI columns;
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
#include <opm/core/utility/CompressedPropertyAccess.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
|
@ -43,9 +44,10 @@
|
|||
struct SetupSimple {
|
||||
SetupSimple()
|
||||
{
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
deck = parser->parseFile("compressed_gridproperty.data");
|
||||
ecl.reset(new Opm::EclipseState(deck));
|
||||
deck = parser->parseFile("compressed_gridproperty.data" , parseMode);
|
||||
ecl.reset(new Opm::EclipseState(deck , parseMode));
|
||||
}
|
||||
|
||||
Opm::DeckConstPtr deck;
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <opm/core/props/BlackoilPhases.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#include <opm/core/pressure/msmfem/partition.h>
|
||||
|
@ -342,9 +343,10 @@ BOOST_AUTO_TEST_CASE (DeckAllDead)
|
|||
{
|
||||
std::shared_ptr<UnstructuredGrid>
|
||||
grid(create_grid_cart3d(1, 1, 10), destroy_grid);
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("deadfluids.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::DeckConstPtr deck = parser->parseFile("deadfluids.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck, parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, *grid, false);
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, *grid, 10.0);
|
||||
const auto& pressures = comp.press();
|
||||
|
@ -370,8 +372,9 @@ BOOST_AUTO_TEST_CASE (CapillaryInversion)
|
|||
Opm::GridManager gm(1, 1, 40, 1.0, 1.0, 2.5);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
// Test the capillary inversion for oil-water.
|
||||
|
@ -423,8 +426,9 @@ BOOST_AUTO_TEST_CASE (DeckWithCapillary)
|
|||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 10.0);
|
||||
|
@ -463,8 +467,9 @@ BOOST_AUTO_TEST_CASE (DeckWithCapillaryOverlap)
|
|||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary_overlap.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("capillary_overlap.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||
|
@ -525,8 +530,9 @@ BOOST_AUTO_TEST_CASE (DeckWithLiveOil)
|
|||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_liveoil.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_liveoil.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||
|
@ -604,8 +610,9 @@ BOOST_AUTO_TEST_CASE (DeckWithLiveGas)
|
|||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_livegas.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_livegas.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||
|
@ -686,8 +693,9 @@ BOOST_AUTO_TEST_CASE (DeckWithRSVDAndRVVD)
|
|||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_rsvd_and_rvvd.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("equil_rsvd_and_rvvd.DATA", parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||
|
||||
Opm::Equil::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/Deck/DeckDoubleItem.hpp>
|
||||
|
||||
|
@ -40,8 +41,9 @@
|
|||
BOOST_AUTO_TEST_CASE(CreateParser)
|
||||
{
|
||||
const std::string filename1 = "testBlackoilState1.DATA";
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile( filename1 );
|
||||
Opm::DeckConstPtr deck = parser->parseFile( filename1 , parseMode);
|
||||
|
||||
BOOST_CHECK_EQUAL( 6U , deck->size() );
|
||||
Opm::DeckItemConstPtr actnum = deck->getKeyword("ACTNUM")->getRecord(0)->getItem(0);
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
#include <opm/core/wells.h>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Well.hpp>
|
||||
|
@ -241,8 +242,9 @@ BOOST_AUTO_TEST_CASE(EclipseReadWriteWellStateData)
|
|||
test_work_area_type * test_area = test_work_area_alloc("EclipseReadWriteWellStateData");
|
||||
|
||||
Opm::Parser parser;
|
||||
Opm::DeckConstPtr deck = parser.parseString(input);
|
||||
Opm::EclipseStatePtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser.parseString(input, parseMode);
|
||||
Opm::EclipseStatePtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::EclipseWriterPtr eclipseWriter = createEclipseWriter(deck, eclipseState, eclipse_data_filename);
|
||||
|
||||
std::shared_ptr<Opm::SimulatorTimer> simTimer( new Opm::SimulatorTimer() );
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <opm/core/props/BlackoilPhases.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#include <opm/core/pressure/msmfem/partition.h>
|
||||
|
@ -66,8 +67,9 @@ BOOST_AUTO_TEST_CASE (GwsegStandard)
|
|||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncStandard.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncStandard.DATA", parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||
|
||||
const int np = 3;
|
||||
|
@ -151,8 +153,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPSBase)
|
|||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPSBase.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPSBase.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||
|
||||
const int np = 3;
|
||||
|
@ -235,9 +238,10 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_A)
|
|||
|
||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_A.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_A.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||
|
||||
const int np = 3;
|
||||
|
@ -482,8 +486,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_C)
|
|||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_C.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_C.DATA", parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||
|
||||
const int np = 3;
|
||||
|
@ -580,8 +585,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_D)
|
|||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_D.DATA");
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_D.DATA" , parseMode);
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||
|
||||
const int np = 3;
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
|
||||
#include <opm/core/wells/WellsManager.hpp>
|
||||
|
@ -43,9 +44,10 @@ BOOST_AUTO_TEST_CASE(TestStoppedWells)
|
|||
{
|
||||
const std::string filename = "wells_stopped.data";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
double target_surfacerate_inj;
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/core/simulator/SimulatorTimer.hpp>
|
||||
#include <opm/core/utility/Units.hpp>
|
||||
|
||||
|
@ -41,7 +42,8 @@ BOOST_AUTO_TEST_CASE(CreateTimer)
|
|||
{
|
||||
const std::string filename1 = "TESTTIMER.DATA";
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr parserDeck = parser->parseFile( filename1 );
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr parserDeck = parser->parseFile( filename1 , parseMode);
|
||||
|
||||
Opm::TimeMapPtr timeMap(new Opm::TimeMap(parserDeck));
|
||||
Opm::SimulatorTimer simtimer;
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include <opm/core/grid/GridManager.hpp> /* compute_geometry */
|
||||
#include <opm/core/grid/cpgpreprocess/preprocess.h>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/Deck/DeckKeyword.hpp>
|
||||
|
||||
|
@ -31,6 +32,7 @@ using namespace std;
|
|||
|
||||
|
||||
BOOST_AUTO_TEST_CASE(Equal) {
|
||||
Opm::ParseMode parseMode;
|
||||
const std::string filename1 = "CORNERPOINT_ACTNUM.DATA";
|
||||
const char *deck2Data =
|
||||
"RUNSPEC\n"
|
||||
|
@ -50,8 +52,8 @@ BOOST_AUTO_TEST_CASE(Equal) {
|
|||
"\n";
|
||||
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck1 = parser->parseFile( filename1 );
|
||||
Opm::DeckConstPtr deck2 = parser->parseString( deck2Data );
|
||||
Opm::DeckConstPtr deck1 = parser->parseFile( filename1 , parseMode);
|
||||
Opm::DeckConstPtr deck2 = parser->parseString( deck2Data , parseMode);
|
||||
|
||||
BOOST_CHECK( deck1->hasKeyword("ZCORN") );
|
||||
BOOST_CHECK( deck1->hasKeyword("COORD") );
|
||||
|
@ -74,7 +76,8 @@ BOOST_AUTO_TEST_CASE(Equal) {
|
|||
BOOST_AUTO_TEST_CASE(EqualEclipseGrid) {
|
||||
const std::string filename = "CORNERPOINT_ACTNUM.DATA";
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck = parser->parseFile( filename );
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = parser->parseFile( filename , parseMode);
|
||||
|
||||
std::shared_ptr<const Opm::EclipseGrid> grid(new Opm::EclipseGrid(deck));
|
||||
|
||||
|
@ -146,8 +149,9 @@ BOOST_AUTO_TEST_CASE(TOPS_Fully_Specified) {
|
|||
"\n";
|
||||
|
||||
Opm::ParserPtr parser(new Opm::Parser() );
|
||||
Opm::DeckConstPtr deck1 = parser->parseString( deck1Data );
|
||||
Opm::DeckConstPtr deck2 = parser->parseString( deck2Data );
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck1 = parser->parseString( deck1Data , parseMode);
|
||||
Opm::DeckConstPtr deck2 = parser->parseString( deck2Data , parseMode);
|
||||
|
||||
std::shared_ptr<const Opm::EclipseGrid> grid1(new Opm::EclipseGrid(deck1));
|
||||
std::shared_ptr<const Opm::EclipseGrid> grid2(new Opm::EclipseGrid(deck2));
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <boost/test/unit_test.hpp>
|
||||
#include <opm/core/wells/WellCollection.hpp>
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Well.hpp>
|
||||
|
@ -40,8 +41,9 @@ using namespace Opm;
|
|||
BOOST_AUTO_TEST_CASE(AddWellsAndGroupToCollection) {
|
||||
ParserPtr parser(new Parser());
|
||||
boost::filesystem::path scheduleFile("wells_group.data");
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string());
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck));
|
||||
ParseMode parseMode;
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string() , parseMode);
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck, parseMode));
|
||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||
|
||||
GroupTreeNodePtr field=eclipseState->getSchedule()->getGroupTree(2)->getNode("FIELD");
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
#include <opm/core/wells/WellsGroup.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Group.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/GroupTreeNode.hpp>
|
||||
|
||||
|
@ -48,8 +49,9 @@ using namespace Opm;
|
|||
BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
||||
ParserPtr parser(new Parser());
|
||||
boost::filesystem::path scheduleFile("wells_group.data");
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string());
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck));
|
||||
ParseMode parseMode;
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string() , parseMode);
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseMode));
|
||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||
|
||||
std::vector<WellConstPtr> wells = eclipseState->getSchedule()->getWells();
|
||||
|
@ -79,9 +81,10 @@ BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
|||
|
||||
BOOST_AUTO_TEST_CASE(ConstructGroupFromGroup) {
|
||||
ParserPtr parser(new Parser());
|
||||
ParseMode parseMode;
|
||||
boost::filesystem::path scheduleFile("wells_group.data");
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string());
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck));
|
||||
DeckConstPtr deck = parser->parseFile(scheduleFile.string() , parseMode);
|
||||
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseMode));
|
||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||
|
||||
std::vector<GroupTreeNodeConstPtr> nodes = eclipseState->getSchedule()->getGroupTree(2)->getNodes();
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
|
||||
#include <opm/core/wells/WellsManager.hpp>
|
||||
|
@ -187,9 +188,10 @@ BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
|||
|
||||
const std::string filename = "wells_manager_data.data";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
{
|
||||
|
@ -226,9 +228,10 @@ BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
|||
BOOST_AUTO_TEST_CASE(WellsEqual) {
|
||||
const std::string filename = "wells_manager_data.data";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||
|
@ -241,10 +244,11 @@ BOOST_AUTO_TEST_CASE(WellsEqual) {
|
|||
|
||||
BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
||||
const std::string filename = "wells_manager_data.data";
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||
|
@ -266,9 +270,10 @@ BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
|||
BOOST_AUTO_TEST_CASE(WellShutOK) {
|
||||
const std::string filename = "wells_manager_data.data";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
Opm::WellsManager wellsManager2(eclipseState , 2 , *gridManager.c_grid(), NULL);
|
||||
|
@ -284,9 +289,10 @@ BOOST_AUTO_TEST_CASE(WellShutOK) {
|
|||
BOOST_AUTO_TEST_CASE(WellSTOPOK) {
|
||||
const std::string filename = "wells_manager_data_wellSTOP.data";
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename));
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
||||
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::GridManager gridManager(deck);
|
||||
|
||||
Opm::WellsManager wellsManager(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
#include <opm/core/wells.h>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Well.hpp>
|
||||
|
@ -135,7 +136,7 @@ std::shared_ptr<Opm::BlackoilState> createBlackOilState(Opm::EclipseGridConstPtr
|
|||
|
||||
Opm::DeckConstPtr createDeck(const std::string& eclipse_data_filename) {
|
||||
Opm::ParserPtr parser(new Opm::Parser());
|
||||
Opm::DeckConstPtr deck = parser->parseFile(eclipse_data_filename);
|
||||
Opm::DeckConstPtr deck = parser->parseFile(eclipse_data_filename , Opm::ParseMode());
|
||||
|
||||
return deck;
|
||||
}
|
||||
|
@ -168,8 +169,9 @@ BOOST_AUTO_TEST_CASE(EclipseWriteRestartWellInfo)
|
|||
test_work_area_type * test_area = test_work_area_alloc("TEST_EclipseWriteNumWells");
|
||||
test_work_area_copy_file(test_area, eclipse_data_filename.c_str());
|
||||
|
||||
Opm::ParseMode parseMode;
|
||||
Opm::DeckConstPtr deck = createDeck(eclipse_data_filename);
|
||||
Opm::EclipseStatePtr eclipseState(new Opm::EclipseState(deck));
|
||||
Opm::EclipseStatePtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
||||
Opm::EclipseWriterPtr eclipseWriter = createEclipseWriter(deck, eclipseState, eclipse_data_filename);
|
||||
|
||||
std::shared_ptr<Opm::SimulatorTimer> simTimer( new Opm::SimulatorTimer() );
|
||||
|
|
|
@ -36,7 +36,7 @@ WELSPECS
|
|||
|
||||
TSTEP
|
||||
14.0 /
|
||||
/
|
||||
|
||||
|
||||
WELSPECS
|
||||
'INJ2' 'G1' 1 1 8335 'GAS' /
|
||||
|
@ -63,7 +63,7 @@ WCONPROD
|
|||
|
||||
TSTEP
|
||||
3 /
|
||||
/
|
||||
|
||||
|
||||
|
||||
END
|
||||
|
|
Loading…
Reference in New Issue
Block a user