Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[relay] Various fixes to make CI green again #4464

Closed
wants to merge 8 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 0 additions & 31 deletions .github/workflows/docusaurus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,48 +11,17 @@ on:
- main

jobs:
build-compiler-explorer:
name: Build Compiler Explorer
runs-on: macos-latest # wasm-pack not working on Ubuntu https://github.com/rustwasm/wasm-pack/issues/781
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.58.0
override: true
- name: Install wasm-pack
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
- name: "Build Compiler Playground Wasm NPM package"
run: wasm-pack build --target web
working-directory: ./compiler/crates/relay-compiler-playground
- uses: actions/upload-artifact@v3
with:
name: compiler-playground-package
path: compiler/crates/relay-compiler-playground/pkg/

build-and-deploy:
runs-on: ubuntu-latest
needs: [build-compiler-explorer]
steps:
- name: Checkout
uses: actions/[email protected]
with:
persist-credentials: false

- name: Download Compiler Explorer
uses: actions/download-artifact@v2
with:
name: compiler-playground-package
path: tmp/compiler-playground-package

- name: Link Compiler Explorer
run: yarn link
working-directory: tmp/compiler-playground-package

- name: Install and Build
run: |
yarn
yarn link relay-compiler-playground
yarn build
working-directory: website/

Expand Down
2 changes: 1 addition & 1 deletion compiler/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions compiler/crates/fixture-tests/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,8 @@ pub async fn test_fixture<T, U, V>(
let actual_result: Result<U, V>;
{
let _guard = LOCK.lock();
colored::control::set_override(false);
env::set_var("NO_COLOR", "1");
actual_result = transform(&fixture).await;
colored::control::unset_override();
}

let actual = match &actual_result {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import type {
} from './__generated__/loadQueryStoreBehaviorTestQuery.graphql';
import type {GraphQLSingularResponse} from 'relay-runtime/network/RelayNetworkTypes';
import type {Sink} from 'relay-runtime/network/RelayObservable';
import type {OperationType, Query} from 'relay-runtime/util/RelayRuntimeTypes';
import type {Query} from 'relay-runtime/util/RelayRuntimeTypes';

const {loadQuery} = require('../loadQuery');
const {
Expand Down
3 changes: 2 additions & 1 deletion scripts/jest/preprocessor.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const path = require('path');

const babelOptions = getBabelOptions({
env: 'test',
// Tests use a Promise polfill so they can use jest.runAllTimers().
// Tests use a Promise polyfill so they can use jest.runAllTimers().
autoImport: true,
plugins: [
'./dist/babel-plugin-relay',
Expand All @@ -28,6 +28,7 @@ const babelOptions = getBabelOptions({
'@babel/plugin-proposal-optional-catch-binding',
'@babel/plugin-proposal-optional-chaining',
'@babel/plugin-transform-async-to-generator',
'babel-plugin-syntax-hermes-parser',
],
});

Expand Down