Skip to content

Commit

Permalink
fix test case
Browse files Browse the repository at this point in the history
  • Loading branch information
ericapywang committed Aug 7, 2024
1 parent 592845f commit 7e47e70
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion codegen/apis
Submodule apis updated from 062b11 to 4de445
16 changes: 9 additions & 7 deletions src/models/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,15 @@ mod embedding;
pub use self::embedding::Embedding;

pub use crate::openapi::models::{
serverless_spec::Cloud, CollectionList, CollectionModel, ConfigureIndexRequest,
ConfigureIndexRequestSpec, ConfigureIndexRequestSpecPod, CreateCollectionRequest,
DeletionProtection, EmbedRequestParameters, IndexModelSpec, IndexModelStatus, IndexSpec,
PodSpec, PodSpecMetadataConfig, ServerlessSpec,
index_model_status::State, serverless_spec::Cloud, CollectionList, CollectionModel,
ConfigureIndexRequest, ConfigureIndexRequestSpec, ConfigureIndexRequestSpecPod,
CreateCollectionRequest, DeletionProtection, EmbedRequestParameters, IndexModelSpec,
IndexModelStatus, IndexSpec, PodSpec, PodSpecMetadataConfig, ServerlessSpec,
};

pub use crate::protos::{DescribeIndexStatsResponse, FetchResponse, ListResponse, QueryResponse, SparseValues,
UpdateResponse, UpsertResponse, Vector};
pub use crate::protos::{
DescribeIndexStatsResponse, FetchResponse, ListResponse, QueryResponse, SparseValues,
UpdateResponse, UpsertResponse, Vector,
};

pub use prost_types::{value::Kind as Kind, Struct as Metadata, Value};
pub use prost_types::{value::Kind, Struct as Metadata, Value};
4 changes: 3 additions & 1 deletion tests/integration_test_control.rs
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,9 @@ async fn test_create_delete_collection() -> Result<(), PineconeError> {
let index_name = &get_pod_index();
loop {
if match pinecone.describe_index(index_name).await {
Ok(index) => index.status.ready,
Ok(index) => {
index.status.ready && (index.status.state == pinecone_sdk::models::State::Ready)
}
Err(_) => false,
} {
break;
Expand Down

0 comments on commit 7e47e70

Please sign in to comment.