Skip to content
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
4 changes: 2 additions & 2 deletions packages/react-relay/__tests__/Catch-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const {RelayEnvironmentProvider, useLazyLoadQuery} = require('react-relay');
const TestRenderer = require('react-test-renderer');
const {RelayFeatureFlags} = require('relay-runtime');
const {graphql} = require('relay-runtime');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore');
const RelayModernStore = require('relay-runtime/store/RelayModernStore');
const RelayRecordSource = require('relay-runtime/store/RelayRecordSource');
const {createMockEnvironment} = require('relay-test-utils');
const {
Expand Down Expand Up @@ -126,7 +126,7 @@ it('should catch a @required(action: THROW) error', () => {

it('should catch Relay Resolver errors', () => {
const environment = createMockEnvironment({
store: new LiveResolverStore(new RelayRecordSource()),
store: new RelayModernStore(new RelayRecordSource()),
});
function TestComponent() {
return (
Expand Down
4 changes: 2 additions & 2 deletions packages/react-relay/__tests__/ClientEdges-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const {
graphql,
} = require('relay-runtime');
const RelayObservable = require('relay-runtime/network/RelayObservable');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore');
const RelayModernStore = require('relay-runtime/store/RelayModernStore');
const {
disallowConsoleErrors,
disallowWarnings,
Expand Down Expand Up @@ -51,7 +51,7 @@ beforeEach(() => {
);

environment = new Environment({
store: new LiveResolverStore(
store: new RelayModernStore(
new RecordSource({
'client:root': {
__id: 'client:root',
Expand Down
58 changes: 29 additions & 29 deletions packages/react-relay/__tests__/LiveResolvers-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ const {
const {
counter_no_fragment: counterNoFragmentResolver,
} = require('relay-runtime/store/__tests__/resolvers/LiveCounterNoFragment');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore');
const RelayModernEnvironment = require('relay-runtime/store/RelayModernEnvironment');
const {
createOperationDescriptor,
} = require('relay-runtime/store/RelayModernOperationDescriptor');
const RelayModernStore = require('relay-runtime/store/RelayModernStore');
const RelayRecordSource = require('relay-runtime/store/RelayRecordSource');
const {
disallowConsoleErrors,
Expand Down Expand Up @@ -77,7 +77,7 @@ test('Can read an external state resolver directly', () => {
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -116,7 +116,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -188,7 +188,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -261,7 +261,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -289,7 +289,7 @@ describe.each([true, false])(
name: 'Alice',
},
});
const store = new LiveResolverStore(source, {gcReleaseBufferSize: 0});
const store = new RelayModernStore(source, {gcReleaseBufferSize: 0});

const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
Expand Down Expand Up @@ -363,7 +363,7 @@ describe.each([true, false])(
}
`;

const store = new LiveResolverStore(source, {gcReleaseBufferSize: 0});
const store = new RelayModernStore(source, {gcReleaseBufferSize: 0});

const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
Expand Down Expand Up @@ -453,7 +453,7 @@ describe.each([true, false])(
}
`;

const store = new LiveResolverStore(source, {gcReleaseBufferSize: 0});
const store = new RelayModernStore(source, {gcReleaseBufferSize: 0});

const mockPayload = Promise.resolve({
data: {
Expand Down Expand Up @@ -525,7 +525,7 @@ describe.each([true, false])(
}
`;

const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -596,7 +596,7 @@ describe.each([true, false])(
}
`;

const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -701,7 +701,7 @@ describe.each([true, false])(
function createEnvironment(source: MutableRecordSource) {
return new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source),
store: new RelayModernStore(source),
});
}

Expand Down Expand Up @@ -940,7 +940,7 @@ describe.each([true, false])(
function createEnvironment(source: MutableRecordSource) {
return new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source),
store: new RelayModernStore(source),
relayFieldLogger,
});
}
Expand Down Expand Up @@ -1062,7 +1062,7 @@ describe.each([true, false])(
function createEnvironment(source: MutableRecordSource) {
return new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source),
store: new RelayModernStore(source),
});
}

Expand Down Expand Up @@ -1166,7 +1166,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -1208,7 +1208,7 @@ describe.each([true, false])(
function createEnvironment(source: MutableRecordSource) {
return new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source),
store: new RelayModernStore(source),
});
}

Expand Down Expand Up @@ -1275,7 +1275,7 @@ describe.each([true, false])(
function createEnvironment(source: MutableRecordSource) {
return new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source),
store: new RelayModernStore(source),
});
}

Expand Down Expand Up @@ -1331,7 +1331,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand All @@ -1351,7 +1351,7 @@ describe.each([true, false])(
test('live resolver with the edge that always suspend', () => {
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(
store: new RelayModernStore(
RelayRecordSource.create({
'client:root': {
__id: 'client:root',
Expand Down Expand Up @@ -1439,7 +1439,7 @@ describe.each([true, false])(
test('correctly suspend on fragments with client-only data', () => {
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(RelayRecordSource.create()),
store: new RelayModernStore(RelayRecordSource.create()),
});
environment.commitPayload(
createOperationDescriptor(
Expand Down Expand Up @@ -1475,7 +1475,7 @@ describe.each([true, false])(
test('invariant for invalid liveState value in the Relay store.', () => {
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(RelayRecordSource.create()),
store: new RelayModernStore(RelayRecordSource.create()),
});
environment.commitPayload(
createOperationDescriptor(
Expand Down Expand Up @@ -1519,7 +1519,7 @@ describe.each([true, false])(
});

test('Subscriptions cleaned up correctly after GC', () => {
const store = new LiveResolverStore(RelayRecordSource.create(), {
const store = new RelayModernStore(RelayRecordSource.create(), {
gcReleaseBufferSize: 0,
});
const environment = new RelayModernEnvironment({
Expand Down Expand Up @@ -1639,7 +1639,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -1669,7 +1669,7 @@ describe.each([true, false])(
`;

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
});

Expand Down Expand Up @@ -1701,7 +1701,7 @@ describe.each([true, false])(
const operation = createOperationDescriptor(FooQuery, {});
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source, {
store: new RelayModernStore(source, {
gcReleaseBufferSize: 0,
}),
});
Expand Down Expand Up @@ -1733,7 +1733,7 @@ describe.each([true, false])(
const operation = createOperationDescriptor(FooQuery, {});
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(source, {
store: new RelayModernStore(source, {
gcReleaseBufferSize: 0,
}),
});
Expand All @@ -1755,7 +1755,7 @@ describe.each([true, false])(
const operation = createOperationDescriptor(FooQuery, {});
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(RelayRecordSource.create(), {
store: new RelayModernStore(RelayRecordSource.create(), {
gcReleaseBufferSize: 0,
}),
});
Expand All @@ -1777,7 +1777,7 @@ describe.each([true, false])(
const operation = createOperationDescriptor(FooQuery, {});
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(RelayRecordSource.create(), {
store: new RelayModernStore(RelayRecordSource.create(), {
gcReleaseBufferSize: 0,
resolverContext: {
greeting: {myHello: 'Hello Allemaal!'},
Expand All @@ -1802,7 +1802,7 @@ describe.each([true, false])(
const operation = createOperationDescriptor(FooQuery, {});
const environment = new RelayModernEnvironment({
network: RelayNetwork.create(jest.fn()),
store: new LiveResolverStore(RelayRecordSource.create(), {
store: new RelayModernStore(RelayRecordSource.create(), {
gcReleaseBufferSize: 0,
resolverContext: {
greeting: {
Expand Down Expand Up @@ -1843,7 +1843,7 @@ describe.each([true, false])(
};

const operation = createOperationDescriptor(FooQuery, {});
const store = new LiveResolverStore(source, {
const store = new RelayModernStore(source, {
gcReleaseBufferSize: 0,
resolverContext: {
counter: Observable.create<number>(observer => {
Expand Down
6 changes: 3 additions & 3 deletions packages/react-relay/__tests__/RelayClient3DModule-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ import {
import RelayNetwork from 'relay-runtime/network/RelayNetwork';
import {graphql} from 'relay-runtime/query/GraphQLTag';
import {resetStore} from 'relay-runtime/store/__tests__/resolvers/ExampleTodoStore';
import LiveResolverStore from 'relay-runtime/store/experimental-live-resolvers/LiveResolverStore';
import RelayModernEnvironment from 'relay-runtime/store/RelayModernEnvironment';
import RelayModernStore from 'relay-runtime/store/RelayModernStore';
import RelayRecordSource from 'relay-runtime/store/RelayRecordSource';
import {
disallowConsoleErrors,
Expand Down Expand Up @@ -124,7 +124,7 @@ describe('ClientUser', () => {
let environment;

beforeEach(() => {
store = new LiveResolverStore(RelayRecordSource.create(), {
store = new RelayModernStore(RelayRecordSource.create(), {
log: logFn,
});
environment = new RelayModernEnvironment({
Expand Down Expand Up @@ -192,7 +192,7 @@ describe('SpecialUser', () => {
let environment;
let store;
beforeEach(() => {
store = new LiveResolverStore(RelayRecordSource.create(), {
store = new RelayModernStore(RelayRecordSource.create(), {
log: logFn,
});
environment = new RelayModernEnvironment({
Expand Down
4 changes: 2 additions & 2 deletions packages/react-relay/__tests__/RelayResolverInterface-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ const {RecordSource} = require('relay-runtime');
const {RelayFeatureFlags} = require('relay-runtime');
const RelayNetwork = require('relay-runtime/network/RelayNetwork');
const {graphql} = require('relay-runtime/query/GraphQLTag');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore.js');
const RelayModernEnvironment = require('relay-runtime/store/RelayModernEnvironment');
const RelayModernStore = require('relay-runtime/store/RelayModernStore.js');
const {
disallowConsoleErrors,
disallowWarnings,
Expand Down Expand Up @@ -57,7 +57,7 @@ function EnvironmentWrapper({
let environment;
let store;
beforeEach(() => {
store = new LiveResolverStore(
store = new RelayModernStore(
new RecordSource({
'client:root': {
__id: 'client:root',
Expand Down
4 changes: 2 additions & 2 deletions packages/react-relay/__tests__/RelayResolverModel-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ const {
const {
LiveColorSubscriptions,
} = require('relay-runtime/store/__tests__/resolvers/TodoDescription');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore.js');
const RelayModernEnvironment = require('relay-runtime/store/RelayModernEnvironment');
const RelayModernStore = require('relay-runtime/store/RelayModernStore.js');
const RelayRecordSource = require('relay-runtime/store/RelayRecordSource');
const {
disallowConsoleErrors,
Expand Down Expand Up @@ -92,7 +92,7 @@ describe.each([true, false])(
let environment;
let store;
beforeEach(() => {
store = new LiveResolverStore(RelayRecordSource.create(), {
store = new RelayModernStore(RelayRecordSource.create(), {
log: logFn,
});
environment = new RelayModernEnvironment({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const {
const {
addTodo,
} = require('relay-runtime/store/__tests__/resolvers/ExampleTodoStore');
const LiveResolverStore = require('relay-runtime/store/experimental-live-resolvers/LiveResolverStore');
const RelayModernStore = require('relay-runtime/store/RelayModernStore');
const {createMockEnvironment} = require('relay-test-utils');

/**
Expand Down Expand Up @@ -194,7 +194,7 @@ function logFn(event: LogEvent): void {
function createEnvironment() {
return new Environment({
network: Network.create(jest.fn()),
store: new LiveResolverStore(RecordSource.create(), {
store: new RelayModernStore(RecordSource.create(), {
log: logFn,
}),
log: logFn,
Expand Down
Loading
Loading