mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
rename ParseMode as ParseContext.
This commit is contained in:
parent
b4a9529aed
commit
c2622708e4
@ -4,7 +4,7 @@
|
|||||||
#include <opm/core/props/BlackoilPhases.hpp>
|
#include <opm/core/props/BlackoilPhases.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
|
|
||||||
#if HAVE_DYNAMIC_BOOST_TEST
|
#if HAVE_DYNAMIC_BOOST_TEST
|
||||||
@ -30,12 +30,12 @@ using namespace std;
|
|||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(EqualsDifferentDeckReturnFalse) {
|
BOOST_AUTO_TEST_CASE(EqualsDifferentDeckReturnFalse) {
|
||||||
|
|
||||||
ParseMode parseMode;
|
ParseContext parseContext;
|
||||||
const string filename1 = "testBlackoilState1.DATA";
|
const string filename1 = "testBlackoilState1.DATA";
|
||||||
const string filename2 = "testBlackoilState2.DATA";
|
const string filename2 = "testBlackoilState2.DATA";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::DeckConstPtr deck1(parser->parseFile(filename1, parseMode));
|
Opm::DeckConstPtr deck1(parser->parseFile(filename1, parseContext));
|
||||||
Opm::DeckConstPtr deck2(parser->parseFile(filename2, parseMode));
|
Opm::DeckConstPtr deck2(parser->parseFile(filename2, parseContext));
|
||||||
|
|
||||||
GridManager gridManager1(deck1);
|
GridManager gridManager1(deck1);
|
||||||
const UnstructuredGrid* grid1 = gridManager1.c_grid();
|
const UnstructuredGrid* grid1 = gridManager1.c_grid();
|
||||||
@ -56,9 +56,9 @@ BOOST_AUTO_TEST_CASE(EqualsDifferentDeckReturnFalse) {
|
|||||||
BOOST_AUTO_TEST_CASE(EqualsDifferentNumPhasesReturnFalse) {
|
BOOST_AUTO_TEST_CASE(EqualsDifferentNumPhasesReturnFalse) {
|
||||||
|
|
||||||
const string filename = "testBlackoilState1.DATA";
|
const string filename = "testBlackoilState1.DATA";
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename, parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename, parseContext));
|
||||||
|
|
||||||
GridManager gridManager(deck);
|
GridManager gridManager(deck);
|
||||||
const UnstructuredGrid* grid = gridManager.c_grid();
|
const UnstructuredGrid* grid = gridManager.c_grid();
|
||||||
@ -77,9 +77,9 @@ BOOST_AUTO_TEST_CASE(EqualsDifferentNumPhasesReturnFalse) {
|
|||||||
BOOST_AUTO_TEST_CASE(EqualsNumericalDifferenceReturnFalse) {
|
BOOST_AUTO_TEST_CASE(EqualsNumericalDifferenceReturnFalse) {
|
||||||
|
|
||||||
const string filename = "testBlackoilState1.DATA";
|
const string filename = "testBlackoilState1.DATA";
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
GridManager gridManager(deck);
|
GridManager gridManager(deck);
|
||||||
const UnstructuredGrid* grid = gridManager.c_grid();
|
const UnstructuredGrid* grid = gridManager.c_grid();
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include <opm/core/props/BlackoilPhases.hpp>
|
#include <opm/core/props/BlackoilPhases.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/DeckItem.hpp>
|
#include <opm/parser/eclipse/Deck/DeckItem.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/DeckRecord.hpp>
|
#include <opm/parser/eclipse/Deck/DeckRecord.hpp>
|
||||||
@ -363,10 +363,10 @@ BOOST_AUTO_TEST_CASE (DeckAllDead)
|
|||||||
{
|
{
|
||||||
std::shared_ptr<UnstructuredGrid>
|
std::shared_ptr<UnstructuredGrid>
|
||||||
grid(create_grid_cart3d(1, 1, 10), destroy_grid);
|
grid(create_grid_cart3d(1, 1, 10), destroy_grid);
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("deadfluids.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("deadfluids.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck, parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck, parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, *grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, *grid, false);
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, *grid, 10.0);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, *grid, 10.0);
|
||||||
const auto& pressures = comp.press();
|
const auto& pressures = comp.press();
|
||||||
@ -392,9 +392,9 @@ BOOST_AUTO_TEST_CASE (CapillaryInversion)
|
|||||||
Opm::GridManager gm(1, 1, 40, 1.0, 1.0, 2.5);
|
Opm::GridManager gm(1, 1, 40, 1.0, 1.0, 2.5);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
// Test the capillary inversion for oil-water.
|
// Test the capillary inversion for oil-water.
|
||||||
@ -446,9 +446,9 @@ BOOST_AUTO_TEST_CASE (DeckWithCapillary)
|
|||||||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("capillary.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 10.0);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 10.0);
|
||||||
@ -487,9 +487,9 @@ BOOST_AUTO_TEST_CASE (DeckWithCapillaryOverlap)
|
|||||||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("capillary_overlap.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("capillary_overlap.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||||
@ -550,9 +550,9 @@ BOOST_AUTO_TEST_CASE (DeckWithLiveOil)
|
|||||||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("equil_liveoil.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("equil_liveoil.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||||
@ -630,9 +630,9 @@ BOOST_AUTO_TEST_CASE (DeckWithLiveGas)
|
|||||||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("equil_livegas.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("equil_livegas.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||||
@ -713,9 +713,9 @@ BOOST_AUTO_TEST_CASE (DeckWithRSVDAndRVVD)
|
|||||||
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 20, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("equil_rsvd_and_rvvd.DATA", parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("equil_rsvd_and_rvvd.DATA", parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, false);
|
||||||
|
|
||||||
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
Opm::EQUIL::DeckDependent::InitialStateComputer comp(props, deck, eclipseState, grid, 9.80665);
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#include <opm/parser/eclipse/Units/ConversionFactors.hpp>
|
#include <opm/parser/eclipse/Units/ConversionFactors.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Tables/TableManager.hpp>
|
#include <opm/parser/eclipse/EclipseState/Tables/TableManager.hpp>
|
||||||
@ -275,13 +275,13 @@ void verify_norne_oil_pvt_region2(Opm::DeckConstPtr deck, Opm::EclipseStateConst
|
|||||||
}
|
}
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE( Test_Norne_PVT) {
|
BOOST_AUTO_TEST_CASE( Test_Norne_PVT) {
|
||||||
Opm::ParseMode parseMode({{ ParseMode::PARSE_RANDOM_SLASH , InputError::IGNORE }});
|
Opm::ParseContext parseContext({{ ParseContext::PARSE_RANDOM_SLASH , InputError::IGNORE }});
|
||||||
Opm::ParserPtr parser(new Parser());
|
Opm::ParserPtr parser(new Parser());
|
||||||
|
|
||||||
std::shared_ptr<const Deck> deck;
|
std::shared_ptr<const Deck> deck;
|
||||||
deck = parser->parseFile("norne_pvt.data", parseMode);
|
deck = parser->parseFile("norne_pvt.data", parseContext);
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclState(new EclipseState(deck, parseMode));
|
Opm::EclipseStateConstPtr eclState(new EclipseState(deck, parseContext));
|
||||||
|
|
||||||
verify_norne_oil_pvt_region1( deck, eclState );
|
verify_norne_oil_pvt_region1( deck, eclState );
|
||||||
verify_norne_oil_pvt_region2( deck, eclState );
|
verify_norne_oil_pvt_region2( deck, eclState );
|
||||||
|
@ -35,7 +35,7 @@
|
|||||||
#include <opm/core/grid.h>
|
#include <opm/core/grid.h>
|
||||||
#include <opm/core/grid/GridManager.hpp>
|
#include <opm/core/grid/GridManager.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/DeckKeyword.hpp>
|
#include <opm/parser/eclipse/Deck/DeckKeyword.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||||
@ -52,9 +52,9 @@ BOOST_AUTO_TEST_CASE(Processing)
|
|||||||
{
|
{
|
||||||
const std::string filename="../tests/testPinch1.DATA";
|
const std::string filename="../tests/testPinch1.DATA";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode({{ ParseMode::PARSE_RANDOM_SLASH , InputError::IGNORE }});
|
Opm::ParseContext parseContext({{ ParseContext::PARSE_RANDOM_SLASH , InputError::IGNORE }});
|
||||||
Opm::DeckConstPtr deck = parser->parseFile(filename, parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile(filename, parseContext);
|
||||||
std::shared_ptr<EclipseState> eclstate (new Opm::EclipseState(deck, parseMode));
|
std::shared_ptr<EclipseState> eclstate (new Opm::EclipseState(deck, parseContext));
|
||||||
std::vector<double> porv = eclstate->getDoubleGridProperty("PORV")->getData();
|
std::vector<double> porv = eclstate->getDoubleGridProperty("PORV")->getData();
|
||||||
EclipseGridConstPtr eclgrid = eclstate->getEclipseGrid();
|
EclipseGridConstPtr eclgrid = eclstate->getEclipseGrid();
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@
|
|||||||
|
|
||||||
#include <opm/core/props/satfunc/RelpermDiagnostics.hpp>
|
#include <opm/core/props/satfunc/RelpermDiagnostics.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
|
|
||||||
BOOST_AUTO_TEST_SUITE ()
|
BOOST_AUTO_TEST_SUITE ()
|
||||||
@ -50,12 +50,12 @@ BOOST_AUTO_TEST_CASE(diagnosis)
|
|||||||
using namespace Opm;
|
using namespace Opm;
|
||||||
EclipseStateConstPtr eclState;
|
EclipseStateConstPtr eclState;
|
||||||
ParserPtr parser(new Opm::Parser);
|
ParserPtr parser(new Opm::Parser);
|
||||||
Opm::ParseMode parseMode({{ ParseMode::PARSE_RANDOM_SLASH , InputError::IGNORE },
|
Opm::ParseContext parseContext({{ ParseContext::PARSE_RANDOM_SLASH , InputError::IGNORE },
|
||||||
{ ParseMode::PARSE_UNKNOWN_KEYWORD, InputError::IGNORE},
|
{ ParseContext::PARSE_UNKNOWN_KEYWORD, InputError::IGNORE},
|
||||||
{ ParseMode::PARSE_RANDOM_TEXT, InputError::IGNORE}
|
{ ParseContext::PARSE_RANDOM_TEXT, InputError::IGNORE}
|
||||||
});
|
});
|
||||||
Opm::DeckConstPtr deck(parser->parseFile("../tests/relpermDiagnostics.DATA", parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile("../tests/relpermDiagnostics.DATA", parseContext));
|
||||||
eclState.reset(new EclipseState(deck, parseMode));
|
eclState.reset(new EclipseState(deck, parseContext));
|
||||||
|
|
||||||
GridManager gm(deck);
|
GridManager gm(deck);
|
||||||
const UnstructuredGrid& grid = *gm.c_grid();
|
const UnstructuredGrid& grid = *gm.c_grid();
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include <opm/core/props/BlackoilPhases.hpp>
|
#include <opm/core/props/BlackoilPhases.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
|
|
||||||
#include <opm/core/pressure/msmfem/partition.h>
|
#include <opm/core/pressure/msmfem/partition.h>
|
||||||
@ -67,9 +67,9 @@ BOOST_AUTO_TEST_CASE (GwsegStandard)
|
|||||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncStandard.DATA", parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("satfuncStandard.DATA", parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||||
|
|
||||||
const int np = 3;
|
const int np = 3;
|
||||||
@ -153,9 +153,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPSBase)
|
|||||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPSBase.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPSBase.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||||
|
|
||||||
const int np = 3;
|
const int np = 3;
|
||||||
@ -238,10 +238,10 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_A)
|
|||||||
|
|
||||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_A.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_A.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||||
|
|
||||||
const int np = 3;
|
const int np = 3;
|
||||||
@ -491,9 +491,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_C)
|
|||||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_C.DATA", parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_C.DATA", parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||||
|
|
||||||
const int np = 3;
|
const int np = 3;
|
||||||
@ -594,9 +594,9 @@ BOOST_AUTO_TEST_CASE (GwsegEPS_D)
|
|||||||
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
Opm::GridManager gm(1, 1, 10, 1.0, 1.0, 5.0);
|
||||||
const UnstructuredGrid& grid = *(gm.c_grid());
|
const UnstructuredGrid& grid = *(gm.c_grid());
|
||||||
Opm::ParserPtr parser(new Opm::Parser() );
|
Opm::ParserPtr parser(new Opm::Parser() );
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_D.DATA" , parseMode);
|
Opm::DeckConstPtr deck = parser->parseFile("satfuncEPS_D.DATA" , parseContext);
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
Opm::BlackoilPropertiesFromDeck props(deck, eclipseState, grid, param, false);
|
||||||
|
|
||||||
const int np = 3;
|
const int np = 3;
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
#include <boost/test/unit_test.hpp>
|
#include <boost/test/unit_test.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||||
|
|
||||||
#include <opm/core/wells/WellsManager.hpp>
|
#include <opm/core/wells/WellsManager.hpp>
|
||||||
@ -44,10 +44,10 @@ BOOST_AUTO_TEST_CASE(TestStoppedWells)
|
|||||||
{
|
{
|
||||||
const std::string filename = "wells_stopped.data";
|
const std::string filename = "wells_stopped.data";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
double target_surfacerate_inj;
|
double target_surfacerate_inj;
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
#include <boost/test/unit_test.hpp>
|
#include <boost/test/unit_test.hpp>
|
||||||
#include <opm/core/wells/WellCollection.hpp>
|
#include <opm/core/wells/WellCollection.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Schedule/Well.hpp>
|
#include <opm/parser/eclipse/EclipseState/Schedule/Well.hpp>
|
||||||
@ -42,9 +42,9 @@ using namespace Opm;
|
|||||||
BOOST_AUTO_TEST_CASE(AddWellsAndGroupToCollection) {
|
BOOST_AUTO_TEST_CASE(AddWellsAndGroupToCollection) {
|
||||||
ParserPtr parser(new Parser());
|
ParserPtr parser(new Parser());
|
||||||
std::string scheduleFile("wells_group.data");
|
std::string scheduleFile("wells_group.data");
|
||||||
ParseMode parseMode;
|
ParseContext parseContext;
|
||||||
DeckConstPtr deck = parser->parseFile(scheduleFile, parseMode);
|
DeckConstPtr deck = parser->parseFile(scheduleFile, parseContext);
|
||||||
EclipseStateConstPtr eclipseState(new EclipseState(deck, parseMode));
|
EclipseStateConstPtr eclipseState(new EclipseState(deck, parseContext));
|
||||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||||
|
|
||||||
GroupTreeNodePtr field=eclipseState->getSchedule()->getGroupTree(2)->getNode("FIELD");
|
GroupTreeNodePtr field=eclipseState->getSchedule()->getGroupTree(2)->getNode("FIELD");
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
#include <opm/core/wells/WellsGroup.hpp>
|
#include <opm/core/wells/WellsGroup.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Schedule/Group.hpp>
|
#include <opm/parser/eclipse/EclipseState/Schedule/Group.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Schedule/GroupTree.hpp>
|
#include <opm/parser/eclipse/EclipseState/Schedule/GroupTree.hpp>
|
||||||
|
|
||||||
@ -50,9 +50,9 @@ using namespace Opm;
|
|||||||
BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
||||||
ParserPtr parser(new Parser());
|
ParserPtr parser(new Parser());
|
||||||
std::string scheduleFile("wells_group.data");
|
std::string scheduleFile("wells_group.data");
|
||||||
ParseMode parseMode;
|
ParseContext parseContext;
|
||||||
DeckConstPtr deck = parser->parseFile(scheduleFile, parseMode);
|
DeckConstPtr deck = parser->parseFile(scheduleFile, parseContext);
|
||||||
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseMode));
|
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseContext));
|
||||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||||
|
|
||||||
std::vector<WellConstPtr> wells = eclipseState->getSchedule()->getWells();
|
std::vector<WellConstPtr> wells = eclipseState->getSchedule()->getWells();
|
||||||
@ -82,10 +82,10 @@ BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
|||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(ConstructGroupFromGroup) {
|
BOOST_AUTO_TEST_CASE(ConstructGroupFromGroup) {
|
||||||
ParserPtr parser(new Parser());
|
ParserPtr parser(new Parser());
|
||||||
ParseMode parseMode;
|
ParseContext parseContext;
|
||||||
std::string scheduleFile("wells_group.data");
|
std::string scheduleFile("wells_group.data");
|
||||||
DeckConstPtr deck = parser->parseFile(scheduleFile, parseMode);
|
DeckConstPtr deck = parser->parseFile(scheduleFile, parseContext);
|
||||||
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseMode));
|
EclipseStateConstPtr eclipseState(new EclipseState(deck , parseContext));
|
||||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||||
|
|
||||||
std::vector<GroupTreeNodeConstPtr> nodes = eclipseState->getSchedule()->getGroupTree(2)->getNodes();
|
std::vector<GroupTreeNodeConstPtr> nodes = eclipseState->getSchedule()->getGroupTree(2)->getNodes();
|
||||||
|
@ -29,17 +29,17 @@
|
|||||||
#include <boost/test/unit_test.hpp>
|
#include <boost/test/unit_test.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
#include <opm/parser/eclipse/Parser/ParseContext.hpp>
|
||||||
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
#include <opm/parser/eclipse/EclipseState/Schedule/Schedule.hpp>
|
||||||
|
|
||||||
#include <opm/core/wells/WellsManager.hpp>
|
#include <opm/core/wells/WellsManager.hpp>
|
||||||
#include <opm/core/wells.h>
|
#include <opm/core/wells.h>
|
||||||
#include <opm/core/well_controls.h>
|
#include <opm/core/well_controls.h>
|
||||||
|
|
||||||
#include <opm/core/grid/GridManager.hpp>
|
#include <opm/core/grid/GridManager.hpp>
|
||||||
|
|
||||||
|
|
||||||
void wells_static_check(const Wells* wells) {
|
void wells_static_check(const Wells* wells) {
|
||||||
BOOST_CHECK_EQUAL(2 , wells->number_of_wells);
|
BOOST_CHECK_EQUAL(2 , wells->number_of_wells);
|
||||||
BOOST_CHECK_EQUAL(3 , wells->number_of_phases);
|
BOOST_CHECK_EQUAL(3 , wells->number_of_phases);
|
||||||
|
|
||||||
@ -58,17 +58,17 @@ void wells_static_check(const Wells* wells) {
|
|||||||
/* Completed cells */
|
/* Completed cells */
|
||||||
BOOST_CHECK_EQUAL(0 , wells->well_cells[0]);
|
BOOST_CHECK_EQUAL(0 , wells->well_cells[0]);
|
||||||
BOOST_CHECK_EQUAL(9 + 2*10 + 2*10*10 , wells->well_cells[1]);
|
BOOST_CHECK_EQUAL(9 + 2*10 + 2*10*10 , wells->well_cells[1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
The number of controls is determined by looking at which elements
|
The number of controls is determined by looking at which elements
|
||||||
have been given explicit - non-default - values in the WCONxxxx
|
have been given explicit - non-default - values in the WCONxxxx
|
||||||
keyword. Is that at all interesting?
|
keyword. Is that at all interesting?
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
void check_controls_epoch0( struct WellControls ** ctrls) {
|
void check_controls_epoch0( struct WellControls ** ctrls) {
|
||||||
// The injector
|
// The injector
|
||||||
{
|
{
|
||||||
const struct WellControls * ctrls0 = ctrls[0];
|
const struct WellControls * ctrls0 = ctrls[0];
|
||||||
@ -117,12 +117,12 @@ void check_controls_epoch0( struct WellControls ** ctrls) {
|
|||||||
BOOST_CHECK_EQUAL( 0 , distr[2] ); // Gas
|
BOOST_CHECK_EQUAL( 0 , distr[2] ); // Gas
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void check_controls_epoch1( struct WellControls ** ctrls) {
|
void check_controls_epoch1( struct WellControls ** ctrls) {
|
||||||
// The injector
|
// The injector
|
||||||
{
|
{
|
||||||
const struct WellControls * ctrls0 = ctrls[0];
|
const struct WellControls * ctrls0 = ctrls[0];
|
||||||
@ -171,27 +171,27 @@ void check_controls_epoch1( struct WellControls ** ctrls) {
|
|||||||
BOOST_CHECK_EQUAL( 1 , distr[2] ); // Gas
|
BOOST_CHECK_EQUAL( 1 , distr[2] ); // Gas
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void check_controls_epoch3( struct WellControls ** ctrls) {
|
void check_controls_epoch3( struct WellControls ** ctrls) {
|
||||||
// The new producer
|
// The new producer
|
||||||
const struct WellControls * ctrls1 = ctrls[1];
|
const struct WellControls * ctrls1 = ctrls[1];
|
||||||
// Note: controls include default (1 atm) BHP control.
|
// Note: controls include default (1 atm) BHP control.
|
||||||
BOOST_CHECK_EQUAL( 6 , well_controls_get_num(ctrls1));
|
BOOST_CHECK_EQUAL( 6 , well_controls_get_num(ctrls1));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
||||||
|
|
||||||
const std::string filename = "wells_manager_data.data";
|
const std::string filename = "wells_manager_data.data";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -221,17 +221,17 @@ BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
|||||||
check_controls_epoch3( wellsManager.c_wells()->ctrls );
|
check_controls_epoch3( wellsManager.c_wells()->ctrls );
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(WellsEqual) {
|
BOOST_AUTO_TEST_CASE(WellsEqual) {
|
||||||
const std::string filename = "wells_manager_data.data";
|
const std::string filename = "wells_manager_data.data";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||||
@ -239,16 +239,16 @@ BOOST_AUTO_TEST_CASE(WellsEqual) {
|
|||||||
|
|
||||||
BOOST_CHECK( wells_equal( wellsManager0.c_wells() , wellsManager0.c_wells(),false) );
|
BOOST_CHECK( wells_equal( wellsManager0.c_wells() , wellsManager0.c_wells(),false) );
|
||||||
BOOST_CHECK( !wells_equal( wellsManager0.c_wells() , wellsManager1.c_wells(),false) );
|
BOOST_CHECK( !wells_equal( wellsManager0.c_wells() , wellsManager1.c_wells(),false) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
||||||
const std::string filename = "wells_manager_data.data";
|
const std::string filename = "wells_manager_data.data";
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
Opm::WellsManager wellsManager0(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||||
@ -263,17 +263,17 @@ BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
|||||||
BOOST_CHECK( !well_controls_equal( wellsManager0.c_wells()->ctrls[1] , wellsManager0.c_wells()->ctrls[0] , false));
|
BOOST_CHECK( !well_controls_equal( wellsManager0.c_wells()->ctrls[1] , wellsManager0.c_wells()->ctrls[0] , false));
|
||||||
BOOST_CHECK( !well_controls_equal( wellsManager1.c_wells()->ctrls[0] , wellsManager0.c_wells()->ctrls[0] , false));
|
BOOST_CHECK( !well_controls_equal( wellsManager1.c_wells()->ctrls[0] , wellsManager0.c_wells()->ctrls[0] , false));
|
||||||
BOOST_CHECK( !well_controls_equal( wellsManager1.c_wells()->ctrls[1] , wellsManager0.c_wells()->ctrls[1] , false));
|
BOOST_CHECK( !well_controls_equal( wellsManager1.c_wells()->ctrls[1] , wellsManager0.c_wells()->ctrls[1] , false));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(WellShutOK) {
|
BOOST_AUTO_TEST_CASE(WellShutOK) {
|
||||||
const std::string filename = "wells_manager_data.data";
|
const std::string filename = "wells_manager_data.data";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
Opm::WellsManager wellsManager2(eclipseState , 2 , *gridManager.c_grid(), NULL);
|
Opm::WellsManager wellsManager2(eclipseState , 2 , *gridManager.c_grid(), NULL);
|
||||||
@ -282,17 +282,17 @@ BOOST_AUTO_TEST_CASE(WellShutOK) {
|
|||||||
BOOST_CHECK( wellsManager2.c_wells()->number_of_wells == 1);
|
BOOST_CHECK( wellsManager2.c_wells()->number_of_wells == 1);
|
||||||
|
|
||||||
//BOOST_CHECK_NO_THROW( Opm::WellsManager wellsManager2(eclipseState , 2 , *gridManager.c_grid(), NULL));
|
//BOOST_CHECK_NO_THROW( Opm::WellsManager wellsManager2(eclipseState , 2 , *gridManager.c_grid(), NULL));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(WellSTOPOK) {
|
BOOST_AUTO_TEST_CASE(WellSTOPOK) {
|
||||||
const std::string filename = "wells_manager_data_wellSTOP.data";
|
const std::string filename = "wells_manager_data_wellSTOP.data";
|
||||||
Opm::ParserPtr parser(new Opm::Parser());
|
Opm::ParserPtr parser(new Opm::Parser());
|
||||||
Opm::ParseMode parseMode;
|
Opm::ParseContext parseContext;
|
||||||
Opm::DeckConstPtr deck(parser->parseFile(filename , parseMode));
|
Opm::DeckConstPtr deck(parser->parseFile(filename , parseContext));
|
||||||
|
|
||||||
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseMode));
|
Opm::EclipseStateConstPtr eclipseState(new Opm::EclipseState(deck , parseContext));
|
||||||
Opm::GridManager gridManager(deck);
|
Opm::GridManager gridManager(deck);
|
||||||
|
|
||||||
Opm::WellsManager wellsManager(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
Opm::WellsManager wellsManager(eclipseState , 0 , *gridManager.c_grid(), NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user