diff --git a/django-postgres/README.md b/django-postgres/README.md index 16d6192..91161b4 100644 --- a/django-postgres/README.md +++ b/django-postgres/README.md @@ -19,25 +19,11 @@ git clone https://github.com/keploy/samples-python.git && cd samples-python/djan Keploy can be installed on Linux directly and on Windows with the help of WSL. Based on your system architecture, install the keploy latest binary release -**1. AMD Architecture** - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_amd64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy -``` - -
- 2. ARM Architecture - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_arm64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy +```bash + curl -O https://raw.githubusercontent.com/keploy/keploy/main/keploy.sh && source keploy.sh + keploy ``` -
- ### Starting the PostgreSQL Instance ```bash diff --git a/fastapi-postgres/README.md b/fastapi-postgres/README.md index 888804d..eca7442 100644 --- a/fastapi-postgres/README.md +++ b/fastapi-postgres/README.md @@ -20,25 +20,11 @@ pip3 install -r requirements.txt Keploy can be installed on Linux directly and on Windows with the help of WSL. Based on your system architecture, install the keploy latest binary release -**1. AMD Architecture** - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_amd64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy -``` - -
- 2. ARM Architecture - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_arm64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy +```bash + curl -O https://raw.githubusercontent.com/keploy/keploy/main/keploy.sh && source keploy.sh + keploy ``` -
- ### Starting the PostgreSQL Instance ```bash @@ -46,12 +32,14 @@ sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy docker-compose up -d ``` +> Note: Update the `SQLALCHEMY_DATABASE_URL` in the `database.py` file if you want to use a keploy with docker. + ### Capture the Testcases This command will start the recording of API calls using ebpf:- ```shell -sudo -E keploy record -c "uvicorn application.main:app --reload" +sudo -E PATH=$PATH keploy record -c "uvicorn application.main:app --reload" ``` Make API Calls using Hoppscotch, Postman or cURL command. Keploy with capture those calls to generate the test-suites containing testcases and data mocks. @@ -118,7 +106,7 @@ Now all these API calls were captured as **editable** testcases and written to ` Now let's run the application in test mode. ```shell -sudo -E keploy test -c "uvicorn application.main:app --reload" --delay 10 +sudo -E PATH=$PATH keploy test -c "uvicorn application.main:app --reload" --delay 10 ``` So, no need to setup fake database/apis like Postgres or write mocks for them. Keploy automatically mocks them and, **The application thinks it's talking to Postgres 😄** diff --git a/fastapi-postgres/application/database.py b/fastapi-postgres/application/database.py index 044ffb7..8b00777 100644 --- a/fastapi-postgres/application/database.py +++ b/fastapi-postgres/application/database.py @@ -3,7 +3,7 @@ from sqlalchemy.orm import sessionmaker -SQLALCHEMY_DATABASE_URL = "postgresql://postgres:postgres@0.0.0.0:5432/studentdb" +SQLALCHEMY_DATABASE_URL = "postgresql://postgres:postgres@postgres:5432/studentdb" engine = create_engine(SQLALCHEMY_DATABASE_URL) SessionLocal = sessionmaker(autocommit=False, autoflush=False, bind=engine) diff --git a/fastapi-postgres/docker-compose.yml b/fastapi-postgres/docker-compose.yml index 8cffd1a..8ce911d 100644 --- a/fastapi-postgres/docker-compose.yml +++ b/fastapi-postgres/docker-compose.yml @@ -11,3 +11,19 @@ services: - "5432:5432" # Map the PostgreSQL port to the host machine volumes: - ./sql/init.sql:/docker-entrypoint-initdb.d/init.sql + networks: + - keploy-network + + app: + container_name: fastapi-app + image: fastapi + build: + context: . + dockerfile: Dockerfile + restart: unless-stopped + ports: + - 8000:8000 + depends_on: + - postgres + networks: + - keploy-network \ No newline at end of file diff --git a/fastapi-postgres/keploy/test-set-0/mocks.yaml b/fastapi-postgres/keploy/test-set-0/mocks.yaml deleted file mode 100755 index e1a173b..0000000 --- a/fastapi-postgres/keploy/test-set-0/mocks.yaml +++ /dev/null @@ -1,1567 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - identifier: StartupRequest - length: 8 - payload: AAAACATSFi8= - ssl_request: - is_ssl: true - auth_type: 0 - postgresresponses: - - payload: Tg== - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - identifier: StartupRequest - payload: AAAAKgADAAB1c2VyAHBvc3RncmVzAGRhdGFiYXNlAHN0dWRlbnRkYgAA - auth_type: 0 - postgresresponses: - - header: [R] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl: - auth_mechanisms: - - SCRAM-SHA-256 - msg_type: 82 - auth_type: 10 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [p] - identifier: ClientRequest - length: 8 - password_message: - password: SCRAM-SHA-256 - msg_type: 112 - auth_type: 0 - postgresresponses: - - header: [R] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl_continue: {data: [114, 61, 52, 74, 86, 106, 122, 74, 112, 52, 47, 119, 114, 53, 76, 107, 84, 51, 47, 80, 100, 82, 122, 65, 109, 99, 112, 117, 117, 82, 118, 49, 67, 99, 87, 86, 114, 102, 122, 72, 79, 51, 51, 82, 105, 77, 105, 105, 52, 98, 44, 115, 61, 66, 89, 47, 121, 78, 51, 75, 102, 49, 117, 90, 109, 90, 69, 100, 85, 72, 111, 68, 105, 117, 81, 61, 61, 44, 105, 61, 52, 48, 57, 54]} - msg_type: 82 - auth_type: 11 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [p] - identifier: ClientRequest - length: 8 - msg_type: 112 - auth_type: 0 - postgresresponses: - - header: [R, R, S, S, S, S, S, S, S, S, S, S, S, S, S, S, K, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl_final: {data: [118, 61, 84, 87, 72, 57, 77, 119, 88, 70, 57, 109, 51, 107, 113, 85, 71, 76, 56, 110, 52, 104, 43, 97, 50, 106, 83, 89, 55, 74, 53, 109, 97, 122, 75, 111, 77, 83, 51, 52, 53, 75, 89, 80, 107, 61]} - backend_key_data: - process_id: 33 - secret_key: 4106888949 - parameter_status: - - name: in_hot_standby - value: "off" - - name: integer_datetimes - value: "on" - - name: TimeZone - value: Etc/UTC - - name: IntervalStyle - value: postgres - - name: is_superuser - value: "on" - - name: application_name - value: "" - - name: default_transaction_read_only - value: "off" - - name: scram_iterations - value: "4096" - - name: DateStyle - value: ISO, MDY - - name: standard_conforming_strings - value: "on" - - name: session_authorization - value: postgres - - name: client_encoding - value: UTF8 - - name: server_version - value: 16.0 (Debian 16.0-1.pgdg120+1) - - name: server_encoding - value: UTF8 - - name: server_encoding - value: UTF8 - - name: server_encoding - value: UTF8 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: | - SELECT t.oid, typarray - FROM pg_type t JOIN pg_namespace ns - ON typnamespace = ns.oid - WHERE typname = 'hstore'; - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 48 - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [111, 105, 100], table_oid: 1247, table_attribute_number: 1, data_type_oid: 26, data_type_size: 4, type_modifier: -1, format: 0}, {name: [116, 121, 112, 97, 114, 114, 97, 121], table_oid: 1247, table_attribute_number: 15, data_type_oid: 26, data_type_size: 4, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: select pg_catalog.version() - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[80, 111, 115, 116, 103, 114, 101, 83, 81, 76, 32, 49, 54, 46, 48, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 54, 46, 48, 45, 49, 46, 112, 103, 100, 103, 49, 50, 48, 43, 49, 41, 32, 111, 110, 32, 120, 56, 54, 95, 54, 52, 45, 112, 99, 45, 108, 105, 110, 117, 120, 45, 103, 110, 117, 44, 32, 99, 111, 109, 112, 105, 108, 101, 100, 32, 98, 121, 32, 103, 99, 99, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 50, 46, 50, 46, 48, 45, 49, 52, 41, 32, 49, 50, 46, 50, 46, 48, 44, 32, 54, 52, 45, 98, 105, 116]]}, {values: [[80, 111, 115, 116, 103, 114, 101, 83, 81, 76, 32, 49, 54, 46, 48, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 54, 46, 48, 45, 49, 46, 112, 103, 100, 103, 49, 50, 48, 43, 49, 41, 32, 111, 110, 32, 120, 56, 54, 95, 54, 52, 45, 112, 99, 45, 108, 105, 110, 117, 120, 45, 103, 110, 117, 44, 32, 99, 111, 109, 112, 105, 108, 101, 100, 32, 98, 121, 32, 103, 99, 99, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 50, 46, 50, 46, 48, 45, 49, 52, 41, 32, 49, 50, 46, 50, 46, 48, 44, 32, 54, 52, 45, 98, 105, 116]]}, {values: [[80, 111, 115, 116, 103, 114, 101, 83, 81, 76, 32, 49, 54, 46, 48, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 54, 46, 48, 45, 49, 46, 112, 103, 100, 103, 49, 50, 48, 43, 49, 41, 32, 111, 110, 32, 120, 56, 54, 95, 54, 52, 45, 112, 99, 45, 108, 105, 110, 117, 120, 45, 103, 110, 117, 44, 32, 99, 111, 109, 112, 105, 108, 101, 100, 32, 98, 121, 32, 103, 99, 99, 32, 40, 68, 101, 98, 105, 97, 110, 32, 49, 50, 46, 50, 46, 48, 45, 49, 52, 41, 32, 49, 50, 46, 50, 46, 48, 44, 32, 54, 52, 45, 98, 105, 116]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [118, 101, 114, 115, 105, 111, 110], table_oid: 0, table_attribute_number: 0, data_type_oid: 25, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: select current_schema() - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[112, 117, 98, 108, 105, 99]]}, {values: [[112, 117, 98, 108, 105, 99]]}, {values: [[112, 117, 98, 108, 105, 99]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [99, 117, 114, 114, 101, 110, 116, 95, 115, 99, 104, 101, 109, 97], table_oid: 0, table_attribute_number: 0, data_type_oid: 19, data_type_size: 64, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: show transaction isolation level - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 72 - - 79 - - 87 - data_row: [{values: [[114, 101, 97, 100, 32, 99, 111, 109, 109, 105, 116, 116, 101, 100]]}, {values: [[114, 101, 97, 100, 32, 99, 111, 109, 109, 105, 116, 116, 101, 100]]}, {values: [[114, 101, 97, 100, 32, 99, 111, 109, 109, 105, 116, 116, 101, 100]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [116, 114, 97, 110, 115, 97, 99, 116, 105, 111, 110, 95, 105, 115, 111, 108, 97, 116, 105, 111, 110], table_oid: 0, table_attribute_number: 0, data_type_oid: 25, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: show standard_conforming_strings - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 72 - - 79 - - 87 - data_row: [{values: [[111, 110]]}, {values: [[111, 110]]}, {values: [[111, 110]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 97, 110, 100, 97, 114, 100, 95, 99, 111, 110, 102, 111, 114, 109, 105, 110, 103, 95, 115, 116, 114, 105, 110, 103, 115], table_oid: 0, table_attribute_number: 0, data_type_oid: 25, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT pg_catalog.pg_class.relname \nFROM pg_catalog.pg_class JOIN pg_catalog.pg_namespace ON pg_catalog.pg_namespace.oid = pg_catalog.pg_class.relnamespace \nWHERE pg_catalog.pg_class.relname = 'students' AND pg_catalog.pg_class.relkind = ANY (ARRAY['r', 'p', 'f', 'v', 'm']) AND pg_catalog.pg_table_is_visible(pg_catalog.pg_class.oid) AND pg_catalog.pg_namespace.nspname != 'pg_catalog'" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[115, 116, 117, 100, 101, 110, 116, 115]]}, {values: [[115, 116, 117, 100, 101, 110, 116, 115]]}, {values: [[115, 116, 117, 100, 101, 110, 116, 115]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [114, 101, 108, 110, 97, 109, 101], table_oid: 1259, table_attribute_number: 2, data_type_oid: 19, data_type_size: 64, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: COMMIT - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 67 - - 79 - - 77 - - 77 - - 73 - - 84 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \n LIMIT 100 OFFSET 0" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 48 - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \nWHERE students.\"Email\" = 'michaelbrown@example.com' \n LIMIT 1" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 48 - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: INSERT INTO students ("Name", "Email", "Hashed Password", "Subject Stream") VALUES ('Michael Brown', 'michaelbrown@example.com', 'snjdibfmcspxo:::', 'Mathematics') RETURNING students."ID" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 73 - - 78 - - 83 - - 69 - - 82 - - 84 - - 32 - - 48 - - 32 - - 49 - data_row: [{values: [[49]]}, {values: [[49]]}, {values: [[49]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: COMMIT - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 67 - - 79 - - 77 - - 77 - - 73 - - 84 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\", students.\"Name\", students.\"Email\", students.\"Hashed Password\", students.\"Subject Stream\" \nFROM students \nWHERE students.\"ID\" = 1" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \nWHERE students.\"ID\" = 11 \n LIMIT 1" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 48 - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \nWHERE students.\"ID\" = 1 \n LIMIT 1" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \n LIMIT 100 OFFSET 0" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: ROLLBACK - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 82 - - 79 - - 76 - - 76 - - 66 - - 65 - - 67 - - 75 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: BEGIN - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 66 - - 69 - - 71 - - 73 - - 78 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: "SELECT students.\"ID\" AS \"students_ID\", students.\"Name\" AS \"students_Name\", students.\"Email\" AS \"students_Email\", students.\"Hashed Password\" AS \"students_Hashed Password\", students.\"Subject Stream\" AS \"students_Subject Stream\" \nFROM students \nWHERE students.\"ID\" = 1 \n LIMIT 1" - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [T, D, C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 83 - - 69 - - 76 - - 69 - - 67 - - 84 - - 32 - - 49 - data_row: [{values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}, {values: [[49], [77, 105, 99, 104, 97, 101, 108, 32, 66, 114, 111, 119, 110], [109, 105, 99, 104, 97, 101, 108, 98, 114, 111, 119, 110, 64, 101, 120, 97, 109, 112, 108, 101, 46, 99, 111, 109], [115, 110, 106, 100, 105, 98, 102, 109, 99, 115, 112, 120, 111, 58, 58, 58], [77, 97, 116, 104, 101, 109, 97, 116, 105, 99, 115]]}] - ready_for_query: - txstatus: 84 - row_description: {fields: [{name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 73, 68], table_oid: 24577, table_attribute_number: 1, data_type_oid: 23, data_type_size: 4, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 78, 97, 109, 101], table_oid: 24577, table_attribute_number: 2, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 69, 109, 97, 105, 108], table_oid: 24577, table_attribute_number: 3, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 72, 97, 115, 104, 101, 100, 32, 80, 97, 115, 115, 119, 111, 114, 100], table_oid: 24577, table_attribute_number: 4, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}, {name: [115, 116, 117, 100, 101, 110, 116, 115, 95, 83, 117, 98, 106, 101, 99, 116, 32, 83, 116, 114, 101, 97, 109], table_oid: 24577, table_attribute_number: 5, data_type_oid: 1043, data_type_size: -1, type_modifier: -1, format: 0}]} - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: DELETE FROM students WHERE students."ID" = 1 - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 68 - - 69 - - 76 - - 69 - - 84 - - 69 - - 32 - - 49 - ready_for_query: - txstatus: 84 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [Q] - identifier: ClientRequest - length: 8 - query: - string: COMMIT - msg_type: 81 - auth_type: 0 - postgresresponses: - - header: [C, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - command_complete: - - command_tag: - - 67 - - 79 - - 77 - - 77 - - 73 - - 84 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - identifier: StartupRequest - payload: AAAAKgADAAB1c2VyAHBvc3RncmVzAGRhdGFiYXNlAHN0dWRlbnRkYgAA - auth_type: 0 - postgresresponses: - - header: [R] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl: - auth_mechanisms: - - SCRAM-SHA-256 - msg_type: 82 - auth_type: 10 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [p] - identifier: ClientRequest - length: 8 - password_message: - password: SCRAM-SHA-256 - msg_type: 112 - auth_type: 0 - postgresresponses: - - header: [R] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl_continue: {data: [114, 61, 104, 65, 52, 72, 75, 114, 50, 75, 103, 51, 111, 66, 110, 76, 108, 120, 97, 78, 113, 50, 51, 110, 97, 97, 49, 113, 98, 70, 100, 86, 48, 121, 86, 51, 115, 113, 116, 87, 116, 108, 115, 54, 73, 51, 97, 117, 83, 110, 44, 115, 61, 87, 115, 114, 48, 101, 50, 78, 57, 105, 51, 55, 51, 89, 121, 78, 105, 47, 53, 120, 100, 86, 81, 61, 61, 44, 105, 61, 52, 48, 57, 54]} - msg_type: 82 - auth_type: 11 ---- -version: api.keploy.io/v1beta2 -kind: Postgres -name: mocks -spec: - metadata: {} - postgresrequests: - - header: [p] - identifier: ClientRequest - length: 8 - msg_type: 112 - auth_type: 0 - postgresresponses: - - header: [R, R, S, S, S, S, S, S, S, S, S, S, S, S, S, S, K, Z] - identifier: ServerResponse - length: 8 - authentication_md5_password: - salt: - - 0 - - 0 - - 0 - - 0 - authentication_sasl_final: {data: [118, 61, 48, 107, 114, 111, 101, 115, 78, 107, 115, 108, 107, 101, 51, 100, 75, 77, 79, 85, 109, 100, 78, 57, 88, 71, 103, 78, 87, 47, 89, 118, 114, 122, 105, 80, 85, 67, 43, 71, 114, 65, 53, 47, 56, 61]} - backend_key_data: - process_id: 54 - secret_key: 1374794602 - parameter_status: - - name: in_hot_standby - value: "off" - - name: integer_datetimes - value: "on" - - name: TimeZone - value: Etc/UTC - - name: IntervalStyle - value: postgres - - name: is_superuser - value: "on" - - name: application_name - value: "" - - name: default_transaction_read_only - value: "off" - - name: scram_iterations - value: "4096" - - name: DateStyle - value: ISO, MDY - - name: standard_conforming_strings - value: "on" - - name: session_authorization - value: postgres - - name: client_encoding - value: UTF8 - - name: server_version - value: 16.0 (Debian 16.0-1.pgdg120+1) - - name: server_encoding - value: UTF8 - - name: server_encoding - value: UTF8 - - name: server_encoding - value: UTF8 - ready_for_query: - txstatus: 73 - msg_type: 90 - auth_type: 0 \ No newline at end of file diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-1.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-1.yaml deleted file mode 100755 index df8342b..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-1.yaml +++ /dev/null @@ -1,45 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-1 -spec: - metadata: {} - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 1d33acb6-386d-45d1-99db-52329895a032 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 404 - header: - Content-Length: "29" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:02 GMT - Server: uvicorn - body: '{"detail":"Data not found!!"}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621766 -curl: | - curl --request GET \ - --url http://127.0.0.1:8000/students/ \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ - --header 'Postman-Token: 1d33acb6-386d-45d1-99db-52329895a032' \ diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-2.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-2.yaml deleted file mode 100755 index 810598c..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-2.yaml +++ /dev/null @@ -1,58 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-2 -spec: - metadata: {} - req: - method: POST - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Content-Length: "121" - Content-Type: application/json - Host: 127.0.0.1:8000 - Postman-Token: aba3841e-82f1-489f-9dda-c1c3e3ef3979 - User-Agent: PostmanRuntime/7.33.0 - body: |4- - { - "name": "Michael Brown", - "email": "michaelbrown@example.com", - "password": "michaelbrown999" - } - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:07 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621770 -curl: |- - curl --request POST \ - --url http://127.0.0.1:8000/students/ \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ - --header 'Postman-Token: aba3841e-82f1-489f-9dda-c1c3e3ef3979' \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ - --header 'Content-Type: application/json' \ - --data ' { - "name": "Michael Brown", - "email": "michaelbrown@example.com", - "password": "michaelbrown999" - }' diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-3.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-3.yaml deleted file mode 100755 index ac81f63..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-3.yaml +++ /dev/null @@ -1,45 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-3 -spec: - metadata: {} - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/11 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 4c94cd86-3b39-4fe6-ba34-df66b82fd932 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 404 - header: - Content-Length: "43" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:21 GMT - Server: uvicorn - body: '{"detail":"Student with ID=11 not found!!"}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621784 -curl: | - curl --request GET \ - --url http://127.0.0.1:8000/students/11 \ - --header 'Postman-Token: 4c94cd86-3b39-4fe6-ba34-df66b82fd932' \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-4.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-4.yaml deleted file mode 100755 index 2abb599..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-4.yaml +++ /dev/null @@ -1,45 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-4 -spec: - metadata: {} - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/1 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: b46c5b40-375c-4956-bcea-84ef922f77f4 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:25 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621789 -curl: | - curl --request GET \ - --url http://127.0.0.1:8000/students/1 \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ - --header 'Postman-Token: b46c5b40-375c-4956-bcea-84ef922f77f4' \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-5.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-5.yaml deleted file mode 100755 index dab53d3..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-5.yaml +++ /dev/null @@ -1,45 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-5 -spec: - metadata: {} - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: cdbe1654-026d-4eaa-a059-1f6374a0c4c7 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "121" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:31 GMT - Server: uvicorn - body: '[{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}]' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621794 -curl: | - curl --request GET \ - --url http://127.0.0.1:8000/students/ \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ - --header 'Postman-Token: cdbe1654-026d-4eaa-a059-1f6374a0c4c7' \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ diff --git a/fastapi-postgres/keploy/test-set-0/tests/test-6.yaml b/fastapi-postgres/keploy/test-set-0/tests/test-6.yaml deleted file mode 100755 index c378e76..0000000 --- a/fastapi-postgres/keploy/test-set-0/tests/test-6.yaml +++ /dev/null @@ -1,45 +0,0 @@ -version: api.keploy.io/v1beta2 -kind: Http -name: test-6 -spec: - metadata: {} - req: - method: DELETE - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/1 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 4eb76f24-2797-486e-bfda-188164f4611e - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:38 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - objects: [] - assertions: - noise: - - header.Date - created: 1697621802 -curl: | - curl --request DELETE \ - --url http://127.0.0.1:8000/students/1 \ - --header 'Postman-Token: 4eb76f24-2797-486e-bfda-188164f4611e' \ - --header 'Host: 127.0.0.1:8000' \ - --header 'Accept-Encoding: gzip, deflate, br' \ - --header 'Connection: keep-alive' \ - --header 'User-Agent: PostmanRuntime/7.33.0' \ - --header 'Accept: */*' \ diff --git a/fastapi-postgres/keploy/testReports/report-1.yaml b/fastapi-postgres/keploy/testReports/report-1.yaml deleted file mode 100755 index 6ec8809..0000000 --- a/fastapi-postgres/keploy/testReports/report-1.yaml +++ /dev/null @@ -1,519 +0,0 @@ -version: api.keploy.io/v1beta1 -name: report-21 -status: PASSED -success: 6 -failure: 0 -total: 6 -tests: - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-1 - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 1d33acb6-386d-45d1-99db-52329895a032 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 404 - header: - Content-Length: "29" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:02 GMT - Server: uvicorn - body: '{"detail":"Data not found!!"}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 404 - actual: 404 - headers_result: - - normal: true - expected: - key: Content-Length - value: - - "29" - actual: - key: Content-Length - value: - - "29" - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:02 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:19 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - body_result: - - normal: true - type: JSON - expected: '{"detail":"Data not found!!"}' - actual: '{"detail":"Data not found!!"}' - dep_result: [] - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-2 - req: - method: POST - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Content-Length: "121" - Content-Type: application/json - Host: 127.0.0.1:8000 - Postman-Token: aba3841e-82f1-489f-9dda-c1c3e3ef3979 - User-Agent: PostmanRuntime/7.33.0 - body: |4- - { - "name": "Michael Brown", - "email": "michaelbrown@example.com", - "password": "michaelbrown999" - } - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:07 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 200 - actual: 200 - headers_result: - - normal: true - expected: - key: Content-Length - value: - - "119" - actual: - key: Content-Length - value: - - "119" - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:07 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:19 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - body_result: - - normal: true - type: JSON - expected: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - actual: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - dep_result: [] - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-3 - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/11 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 4c94cd86-3b39-4fe6-ba34-df66b82fd932 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 404 - header: - Content-Length: "43" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:21 GMT - Server: uvicorn - body: '{"detail":"Student with ID=11 not found!!"}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 404 - actual: 404 - headers_result: - - normal: true - expected: - key: Content-Length - value: - - "43" - actual: - key: Content-Length - value: - - "43" - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:21 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:20 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - body_result: - - normal: true - type: JSON - expected: '{"detail":"Student with ID=11 not found!!"}' - actual: '{"detail":"Student with ID=11 not found!!"}' - dep_result: [] - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-4 - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/1 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: b46c5b40-375c-4956-bcea-84ef922f77f4 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:25 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 200 - actual: 200 - headers_result: - - normal: true - expected: - key: Content-Length - value: - - "119" - actual: - key: Content-Length - value: - - "119" - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:25 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:20 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - body_result: - - normal: true - type: JSON - expected: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - actual: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - dep_result: [] - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-5 - req: - method: GET - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/ - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: cdbe1654-026d-4eaa-a059-1f6374a0c4c7 - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "121" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:31 GMT - Server: uvicorn - body: '[{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}]' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 200 - actual: 200 - headers_result: - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:31 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:20 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - - normal: true - expected: - key: Content-Length - value: - - "121" - actual: - key: Content-Length - value: - - "121" - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - body_result: - - normal: true - type: JSON - expected: '[{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}]' - actual: '[{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}]' - dep_result: [] - - kind: Http - name: report-21 - status: PASSED - started: 1697621960 - completed: 1697621960 - test_case_path: /home/shashwat/Projects/fastapi-postgres/keploy/test-set-3 - mock_path: "" - test_case_id: test-6 - req: - method: DELETE - proto_major: 1 - proto_minor: 1 - url: http://127.0.0.1:8000/students/1 - header: - Accept: '*/*' - Accept-Encoding: gzip, deflate, br - Connection: keep-alive - Host: 127.0.0.1:8000 - Postman-Token: 4eb76f24-2797-486e-bfda-188164f4611e - User-Agent: PostmanRuntime/7.33.0 - body: "" - body_type: "" - resp: - status_code: 200 - header: - Content-Length: "119" - Content-Type: application/json - Date: Wed, 18 Oct 2023 09:36:38 GMT - Server: uvicorn - body: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - body_type: "" - status_message: "" - proto_major: 0 - proto_minor: 0 - noise: - - header.Date - result: - status_code: - normal: true - expected: 200 - actual: 200 - headers_result: - - normal: true - expected: - key: Content-Type - value: - - application/json - actual: - key: Content-Type - value: - - application/json - - normal: true - expected: - key: Date - value: - - Wed, 18 Oct 2023 09:36:38 GMT - actual: - key: Date - value: - - Wed, 18 Oct 2023 09:39:20 GMT - - normal: true - expected: - key: Server - value: - - uvicorn - actual: - key: Server - value: - - uvicorn - - normal: true - expected: - key: Content-Length - value: - - "119" - actual: - key: Content-Length - value: - - "119" - body_result: - - normal: true - type: JSON - expected: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - actual: '{"name":"Michael Brown","email":"michaelbrown@example.com","password":"snjdibfmcspxo:::","stream":"Mathematics","id":1}' - dep_result: [] -test_set: test-set-3 diff --git a/fastapi-postgres/sql/init.sql b/fastapi-postgres/sql/init.sql index aaa55f3..c42858b 100644 --- a/fastapi-postgres/sql/init.sql +++ b/fastapi-postgres/sql/init.sql @@ -1,2 +1,2 @@ -DROP DATABASE studentdb IF EXISTS; -CREATE DATABASE studentdb; \ No newline at end of file +CREATE DATABASE studentdb; +DROP DATABASE IF EXISTS studentdb; \ No newline at end of file diff --git a/fastapi-twilio/README.md b/fastapi-twilio/README.md index 06bbc82..0afbc7e 100644 --- a/fastapi-twilio/README.md +++ b/fastapi-twilio/README.md @@ -13,25 +13,11 @@ pip3 install -r requirements.txt Keploy can be installed on Linux directly and on Windows with the help of WSL. Based on your system architecture, install the keploy latest binary release -**1. AMD Architecture** - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_amd64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy -``` - -
- 2. ARM Architecture - -```shell -curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_arm64.tar.gz" | tar xz -C /tmp - -sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin && keploy +```bash + curl -O https://raw.githubusercontent.com/keploy/keploy/main/keploy.sh && source keploy.sh + keploy ``` -
- ### Get your Twilio Credentials You can get your Twilio credentials by signing in to [Twilio Console](https://console.twilio.com/).