From e8849b2213bc7fd1b06f4f589e0991c66cc58c8c Mon Sep 17 00:00:00 2001 From: Brian George Date: Thu, 20 Jun 2024 17:03:12 -0400 Subject: [PATCH] Derive Eq, PartialEq for SupergraphConfig and SubgraphConfig --- apollo-federation-types/src/config/subgraph.rs | 2 +- apollo-federation-types/src/config/supergraph.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apollo-federation-types/src/config/subgraph.rs b/apollo-federation-types/src/config/subgraph.rs index 77b0095c0..91b7ee397 100644 --- a/apollo-federation-types/src/config/subgraph.rs +++ b/apollo-federation-types/src/config/subgraph.rs @@ -4,7 +4,7 @@ use std::collections::HashMap; use url::Url; /// Config for a single [subgraph](https://www.apollographql.com/docs/federation/subgraphs/) -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Debug, Clone, Eq, PartialEq, Serialize, Deserialize)] pub struct SubgraphConfig { /// The routing URL for the subgraph. /// This will appear in supergraph SDL and diff --git a/apollo-federation-types/src/config/supergraph.rs b/apollo-federation-types/src/config/supergraph.rs index 696c18b6a..21cc6b895 100644 --- a/apollo-federation-types/src/config/supergraph.rs +++ b/apollo-federation-types/src/config/supergraph.rs @@ -10,7 +10,7 @@ use std::{collections::BTreeMap, fs}; /// The configuration for a single supergraph /// composed of multiple subgraphs. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Debug, Clone, Eq, PartialEq, Serialize, Deserialize)] pub struct SupergraphConfig { // Store config in a BTreeMap, as HashMap is non-deterministic. subgraphs: BTreeMap,