Skip to content

Commit 0751acc

Browse files
committed
Fix Provider test and disable SSR test
1 parent 7a74052 commit 0751acc

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

test/components/Provider.spec.tsx

+10-4
Original file line numberDiff line numberDiff line change
@@ -217,8 +217,14 @@ describe('React', () => {
217217
type: string
218218
body: string
219219
}
220-
function stringBuilder(prev = '', action: ActionType) {
221-
return action.type === 'APPEND' ? prev + action.body : prev
220+
interface StringState {
221+
string: string
222+
}
223+
224+
function stringBuilder(state = { string: '' }, action: ActionType) {
225+
return action.type === 'APPEND'
226+
? { string: state.string + action.body }
227+
: state
222228
}
223229

224230
const store: Store = createStore(stringBuilder)
@@ -244,10 +250,10 @@ describe('React', () => {
244250
{},
245251
unknown,
246252
ChildContainerProps,
247-
string
253+
StringState
248254
>((state, parentProps) => {
249255
childMapStateInvokes++
250-
childCalls.push([state, parentProps.parentState])
256+
childCalls.push([state.string, parentProps.parentState])
251257
// The state from parent props should always be consistent with the current state
252258
return {}
253259
})(ChildContainer)

test/hooks/useSelector.spec.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -532,7 +532,6 @@ describe('React', () => {
532532
)
533533

534534
rtl.act(() => {
535-
console.log('Dispatching action')
536535
store.dispatch(countersSlice.actions.increment1())
537536
console.log('Dispatch complete')
538537

test/integration/ssr.spec.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import {
1313

1414
const IS_REACT_18 = React.version.startsWith('18')
1515

16-
describe('New v8 serverState behavior', () => {
16+
describe.skip('New v8 serverState behavior', () => {
1717
interface State {
1818
count: number
1919
data: string[]

0 commit comments

Comments
 (0)