2019-06-05 04:26:19 -05:00
|
|
|
import sys
|
|
|
|
import os
|
|
|
|
import tempfile
|
2019-06-05 08:45:22 -05:00
|
|
|
import pytest
|
2019-08-14 02:43:44 -05:00
|
|
|
import grpc
|
2019-06-05 04:26:19 -05:00
|
|
|
|
2021-01-26 13:48:01 -06:00
|
|
|
sys.path.insert(1, os.path.join(sys.path[0], "../../"))
|
2019-06-05 04:26:19 -05:00
|
|
|
import rips
|
|
|
|
|
|
|
|
import dataroot
|
2021-01-26 13:34:31 -06:00
|
|
|
|
2021-01-26 13:48:01 -06:00
|
|
|
|
2021-01-26 13:34:31 -06:00
|
|
|
def test_create_lgr_well(rips_instance, initialize_test):
|
|
|
|
case = rips_instance.project.load_case(
|
2021-01-26 13:48:01 -06:00
|
|
|
dataroot.PATH + "/TEST10K_FLT_LGR_NNC/TEST10K_FLT_LGR_NNC.EGRID"
|
|
|
|
)
|
|
|
|
assert case.name == "TEST10K_FLT_LGR_NNC"
|
|
|
|
assert len(case.grids()) == 2
|
2021-01-26 13:34:31 -06:00
|
|
|
|
2021-01-26 13:48:01 -06:00
|
|
|
well_files = [dataroot.PATH + "/TEST10K_FLT_LGR_NNC/wellpath_a.dev"]
|
2021-01-26 13:34:31 -06:00
|
|
|
rips_instance.project.import_well_paths(well_path_files=well_files)
|
|
|
|
|
2021-01-26 13:48:01 -06:00
|
|
|
time_step = 5
|
|
|
|
well_path_names = ["Well Path A"]
|
|
|
|
case.create_lgr_for_completion(
|
|
|
|
time_step,
|
|
|
|
well_path_names,
|
|
|
|
refinement_i=2,
|
|
|
|
refinement_j=3,
|
|
|
|
refinement_k=1,
|
|
|
|
split_type="LGR_PER_WELL",
|
|
|
|
)
|
|
|
|
assert len(case.grids()) == 3
|