Giter Club home page Giter Club logo

http-mock-server's Introduction

晒酷学院

软件测试视频教程

软件测试交流学习群


扫码加入微信学习交流群

avatar

Mock Server Tools


Mock server used to support for testing as substitution of the real server.

Features

  • HTTP protocol api mock service
  • HTTPS protocol api mock service, certificates are stored in the securities directory

Where and What form are the Mock Data Store?

  • Commons

    All types of mock service can be stored into DB(Mysql), Mongo, File, but for the different store type mush have one data loader which should implements MockDataLoader, and explicit specify the implementation with property mock.server.http.data-loader

  • Http(s) mock service
  • Soap mock service

Steps for using ssl mock server

1.modify the application.yml

spring:
  profiles:
    active: dev

2.run the command in IDEA

mvn clean compile -Pdev

3.modify the mysql name in application-dev.yml

urdataSource-1l: jdbc:mysql://localhost:3306/mock-server?serverTimezone=UTC&useUnicode=true&zeroDateTimeBehavior=convertToNull&autoReconnect=true&characterEncoding=utf-8&useSSL=false

4.if your password forgotten 4.1 run the below command firstly after stop the mysql service by manual

C:\Program Files\MySQL\MySQL Server 5.7\bin>mysqld --defaults-file="C:\ProgramData\MySQL\MySQL Server 5.7\my.ini" --console --skip-grant-tables

4.2 enter mysql console

C:\Program Files\MySQL\MySQL Server 5.7\bin>mysql -uroot

4.3 update root's password to 123456

mysql> update user SET `authentication_string` = PASSWORD('root');
Query OK, 4 rows affected, 1 warning (0.00 sec)
Rows matched: 4  Changed: 4  Warnings: 1
mysql> update user set authentication_string='123456' where user='root';
Query OK, 2 rows affected (0.00 sec)
Rows matched: 2  Changed: 2  Warnings: 0
mysql> select user,host,authentication_string from user;
+-----------+-----------+-------------------------------------------+
| user      | host      | authentication_string                     |
+-----------+-----------+-------------------------------------------+
| root      | localhost | 123456                                    |
| mysql.sys | localhost | *81F5E21E35407D884A6CD4A731AEBFB6AF209E1B |
| user      | %         | *81F5E21E35407D884A6CD4A731AEBFB6AF209E1B |
| root      | %         | 123456                                    |
+-----------+-----------+-------------------------------------------+
4 rows in set (0.00 sec)

5.enter http://localhost:8080/ in your web browser

http-mock-server's People

Contributors

dependabot[bot] avatar shaikuba avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.