Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into feature/support-array…
Browse files Browse the repository at this point in the history
…-for-field-value
  • Loading branch information
bhongy committed Sep 7, 2023
2 parents 36355c4 + 470a405 commit c43474a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 9 deletions.
14 changes: 7 additions & 7 deletions packages/formspree-core/test/core.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ describe('Client.submitForm', () => {
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand Down Expand Up @@ -434,7 +434,7 @@ describe('Client.submitForm', () => {
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand Down Expand Up @@ -489,7 +489,7 @@ describe('Client.submitForm', () => {
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand Down Expand Up @@ -551,7 +551,7 @@ describe('Client.submitForm', () => {
body: data,
headers: {
Accept: 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand All @@ -565,7 +565,7 @@ describe('Client.submitForm', () => {
body: data,
headers: {
Accept: 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand Down Expand Up @@ -614,7 +614,7 @@ describe('Client.submitForm', () => {
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand All @@ -634,7 +634,7 @@ describe('Client.submitForm', () => {
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
'Formspree-Client': '@formspree/core@2.8.3',
'Formspree-Client': `@formspree/core@${version}`,
'Formspree-Session-Data': expectedSessionData,
},
method: 'POST',
Expand Down
8 changes: 6 additions & 2 deletions packages/formspree-react/test/useForm.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ describe('useForm', () => {
body: expect.any(FormData),
headers: {
Accept: 'application/json',
'Formspree-Client': '@formspree/[email protected] @formspree/[email protected]',
'Formspree-Client': expect.stringMatching(
/^@formspree\/react@[\d.]+ @formspree\/core@[\d.]+$/
),
'Formspree-Session-Data': expect.any(String),
},
method: 'POST',
Expand Down Expand Up @@ -141,7 +143,9 @@ describe('useForm', () => {
body: expect.any(FormData),
headers: {
Accept: 'application/json',
'Formspree-Client': '@formspree/[email protected] @formspree/[email protected]',
'Formspree-Client': expect.stringMatching(
/^@formspree\/react@[\d.]+ @formspree\/core@[\d.]+$/
),
'Formspree-Session-Data': expect.any(String),
},
method: 'POST',
Expand Down

0 comments on commit c43474a

Please sign in to comment.