Skip to content

Commit

Permalink
add integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
morgandu committed Nov 25, 2021
1 parent 8895cb5 commit 56285ae
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
17 changes: 5 additions & 12 deletions tests/system/aiplatform/test_featurestore.py
Expand Up @@ -16,6 +16,7 @@
#

from google.cloud import aiplatform
from google.cloud.aiplatform import _featurestores as featurestores
from tests.system.aiplatform import e2e_base


Expand All @@ -29,16 +30,8 @@ def test_create_and_get_featurestore(self, shared_state):
project=e2e_base._PROJECT, location=e2e_base._LOCATION,
)

display_name = self._make_display_name("tensorboard")
list_featurestores = featurestores.Featurestore.list()
assert len(list_featurestores) >= 0

tb = aiplatform.Tensorboard.create(display_name=display_name)

shared_state["resources"] = [tb]

get_tb = aiplatform.Tensorboard(tb.resource_name)

assert tb.resource_name == get_tb.resource_name

list_tb = aiplatform.Tensorboard.list()

assert len(list_tb) > 0
list_searched_features = featurestores.Featurestore.search_features()
assert len(list_searched_features) >= 0
2 changes: 1 addition & 1 deletion tests/unit/aiplatform/test_featurestores.py
Expand Up @@ -356,7 +356,7 @@ def test_validate_and_get_featurestore_resource_id(self, featurestore_name: str)
)
)

def test_validate_and_get_featurestore_resource_ids_with_raise(self,):
def test_validate_and_get_featurestore_resource_id_with_raise(self,):
with pytest.raises(ValueError):
featurestore_utils.validate_and_get_featurestore_resource_id(
featurestore_name=_TEST_FEATURESTORE_INVALID
Expand Down

0 comments on commit 56285ae

Please sign in to comment.