Skip to content

Commit

Permalink
bump spec_version in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
zorancv committed Jan 28, 2025
1 parent 47176c8 commit 81f0a57
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 10 deletions.
3 changes: 2 additions & 1 deletion graph/src/schema/input/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1049,7 +1049,8 @@ impl InputSchema {
})
}

/// Parse with the latest spec version
/// Parse with the latest spec version, it should be used only in tests.
#[cfg(debug_assertions)]
pub fn parse_latest(raw: &str, id: DeploymentHash) -> Result<Self, Error> {
use crate::data::subgraph::LATEST_VERSION;

Expand Down
4 changes: 2 additions & 2 deletions store/test-store/src/store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ pub async fn create_subgraph(

let manifest = SubgraphManifest::<graph::blockchain::mock::MockBlockchain> {
id: subgraph_id.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: BTreeSet::new(),
description: Some(format!("manifest for {}", subgraph_id)),
repository: Some(format!("repo for {}", subgraph_id)),
Expand Down Expand Up @@ -227,7 +227,7 @@ pub async fn create_test_subgraph_with_features(

let manifest = SubgraphManifest::<graph::blockchain::mock::MockBlockchain> {
id: subgraph_id.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features,
description: Some(format!("manifest for {}", subgraph_id)),
repository: Some(format!("repo for {}", subgraph_id)),
Expand Down
2 changes: 1 addition & 1 deletion store/test-store/tests/graph/entity_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ where
async fn insert_test_data(store: Arc<DieselSubgraphStore>) -> DeploymentLocator {
let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id: LOAD_RELATED_ID.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down
2 changes: 1 addition & 1 deletion store/test-store/tests/postgres/graft.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ where
async fn insert_test_data(store: Arc<DieselSubgraphStore>) -> DeploymentLocator {
let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id: TEST_SUBGRAPH_ID.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down
4 changes: 2 additions & 2 deletions store/test-store/tests/postgres/store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ where
async fn insert_test_data(store: Arc<DieselSubgraphStore>) -> DeploymentLocator {
let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id: TEST_SUBGRAPH_ID.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down Expand Up @@ -1270,7 +1270,7 @@ fn entity_changes_are_fired_and_forwarded_to_subscriptions() {
.expect("Failed to parse user schema");
let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id: subgraph_id.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down
4 changes: 2 additions & 2 deletions store/test-store/tests/postgres/subgraph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ fn create_subgraph() {

let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id,
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down Expand Up @@ -543,7 +543,7 @@ fn subgraph_features() {
} = get_subgraph_features(id.to_string()).unwrap();

assert_eq!(NAME, subgraph_id.as_str());
assert_eq!("1.0.0", spec_version);
assert_eq!("1.3.0", spec_version);
assert_eq!("1.0.0", api_version.unwrap());
assert_eq!(NETWORK_NAME, network);
assert_eq!(
Expand Down
2 changes: 1 addition & 1 deletion store/test-store/tests/postgres/writable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ lazy_static! {
async fn insert_test_data(store: Arc<DieselSubgraphStore>) -> DeploymentLocator {
let manifest = SubgraphManifest::<graph_chain_ethereum::Chain> {
id: TEST_SUBGRAPH_ID.clone(),
spec_version: Version::new(1, 0, 0),
spec_version: Version::new(1, 3, 0),
features: Default::default(),
description: None,
repository: None,
Expand Down

0 comments on commit 81f0a57

Please sign in to comment.