Skip to content

Commit

Permalink
Merge pull request #449 from mathstuf/gha-ignore-forks
Browse files Browse the repository at this point in the history
gha: only run on the main repo
  • Loading branch information
mathstuf authored Oct 13, 2023
2 parents 33b8a34 + a3c47f7 commit 900c432
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ jobs:
os: [ubuntu-latest, macos-latest]
name: Cargo test
runs-on: ${{ matrix.os }}
if: "github.repository == 'graphql-rust/graphql-client'"
steps:
- name: Checkout sources
uses: actions/checkout@v2
Expand All @@ -32,6 +33,7 @@ jobs:
wasm_build:
name: Cargo build for wasm
runs-on: ubuntu-latest
if: "github.repository == 'graphql-rust/graphql-client'"
steps:
- name: Checkout sources
uses: actions/checkout@v2
Expand All @@ -48,6 +50,7 @@ jobs:
lint:
name: Rustfmt and Clippy
runs-on: ubuntu-latest
if: "github.repository == 'graphql-rust/graphql-client'"
steps:
- name: Checkout sources
uses: actions/checkout@v2
Expand All @@ -65,6 +68,7 @@ jobs:
prettier:
name: Check prettier
runs-on: ubuntu-latest
if: "github.repository == 'graphql-rust/graphql-client'"
steps:
- name: Checkout sources
uses: actions/checkout@v2
Expand Down
4 changes: 2 additions & 2 deletions graphql_client/tests/operation_selection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ pub struct Heights;
)]
pub struct Echo;

const HEIGHTS_RESPONSE: &str = r##"{"mountainHeight": 224, "buildingHeight": 12}"##;
const ECHO_RESPONSE: &str = r##"{"echo": "tiramisù"}"##;
const HEIGHTS_RESPONSE: &str = r#"{"mountainHeight": 224, "buildingHeight": 12}"#;
const ECHO_RESPONSE: &str = r#"{"echo": "tiramisù"}"#;

#[test]
fn operation_selection_works() {
Expand Down
2 changes: 1 addition & 1 deletion graphql_client_codegen/src/schema/json_conversion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ fn ingest_object(schema: &mut Schema, object: &mut FullType) {
})
.collect()
})
.unwrap_or_else(Vec::new),
.unwrap_or_default(),
fields: field_ids,
};

Expand Down

0 comments on commit 900c432

Please sign in to comment.