Skip to content

Commit

Permalink
fix body and response in mock http type (#30)
Browse files Browse the repository at this point in the history
* fix body and response in mock http type

* Bump version

---------

Co-authored-by: Ab C <[email protected]>
  • Loading branch information
fantazista and abdala authored Nov 26, 2024
1 parent b5f15bb commit 3dabdaa
Show file tree
Hide file tree
Showing 10 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion assert/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/assert",
"version": "0.10.3",
"version": "0.10.4",
"description": "Extra assert library",
"type": "module",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion dtc-aws-plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/dtc-aws-plugin",
"version": "0.10.3",
"version": "0.10.4",
"description": "AWS plugin for Declarative TestCases",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion dtc-graphql-plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/dtc-graphql-plugin",
"version": "0.10.3",
"version": "0.10.4",
"description": "GraphQl plugin for Declarative TestCases",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion dtc-mysql-plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/dtc-mysql-plugin",
"version": "0.10.3",
"version": "0.10.4",
"description": "MySQL plugin for Declarative TestCases",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion dtc-playwright-plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/dtc-playwright-plugin",
"version": "0.10.3",
"version": "0.10.4",
"description": "Playwright plugin for Declarative TestCases",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion dtc/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/dtc",
"version": "0.10.3",
"version": "0.10.4",
"description": "Declarative TestCases",
"repository": {
"type": "git",
Expand Down
6 changes: 3 additions & 3 deletions dtc/src/plugins/http-mock-plugin.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import nodeAssert from 'node:assert/strict'
import extraAssert from '@cgauge/assert'
import nock from 'nock'
import {is, optional, record, union} from '@cgauge/type-guard'
import {is, optional, record, union, unknown} from '@cgauge/type-guard'

const MockHttp = {
url: String,
Expand All @@ -10,8 +10,8 @@ const MockHttp = {
status: optional(Number),
queries: optional(record(String, union(String, [String]))),
headers: optional(record(String, String)),
body: optional(union(String, record(String, String))),
response: optional(union(String, record(String, String))),
body: optional(union(String, record(String, unknown))),
response: optional(union(String, record(String, unknown))),
}

export const partialBodyCheck = (expected: string | Record<string, unknown>) => (body: Record<string, unknown>) => {
Expand Down
2 changes: 1 addition & 1 deletion nock-aws/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/nock-aws",
"version": "0.10.3",
"version": "0.10.4",
"description": "AWS Request mocker based on Nock",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion type-guard/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/type-guard",
"version": "0.10.3",
"version": "0.10.4",
"description": "Typescript type guards",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion yaml/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cgauge/yaml",
"version": "0.10.3",
"version": "0.10.4",
"description": "YAML parser with extra tags",
"repository": {
"type": "git",
Expand Down

0 comments on commit 3dabdaa

Please sign in to comment.