September 2023 Summaries
3 posts from WireMock
Filter
Month:
Year:
Post Summaries
Back to Blog
Hacktoberfest, a month-long celebration of open source software, is a global online hackathon that has grown significantly since its inception, attracting nearly 147,000 participants last year. The 2023 edition, supported by DigitalOcean, ILLA Cloud, and AppWrite, includes the WireMock project as a participant in its 10th edition. Contributors can support open source by making various contributions to the WireMock ecosystem, ranging from code contributions in languages like Java, Python, and Rust to non-code contributions like documentation and community support. Participants are encouraged to share their contributions on social media or designated channels to ensure recognition. Active contributors are rewarded with digital awards, and select participants receive T-shirts, stickers, and other swag. WireMock emphasizes quality and value in assessing contributions and encourages adherence to its Code of Conduct during the event.
Sep 26, 2023
603 words in the original blog post.
Dynamic response templating is a feature in WireMock Cloud that allows a mock API to deliver varying data with a single stub by utilizing request values in responses, thereby simulating real-world API behavior more effectively. This technique is particularly useful when testing systems that interact with APIs, as it enables the testing of different scenarios without the need for multiple static responses. By using response templating, developers can create a more realistic and efficient testing environment, as demonstrated in the article through a CRM API example. In this scenario, rather than setting up separate responses for each contact ID, a dynamic response is generated using a single template, which includes a placeholder for the contact ID derived from the request URL. This not only makes the mock API more adaptable but also simplifies maintenance. The process involves creating a stub with a GET method, enabling dynamic response templating using a handlebars system, and setting up a JSON response template that dynamically inserts the contact ID.
Sep 19, 2023
667 words in the original blog post.
Eiki Hayashi, a web engineer, introduced a GraphQL extension for WireMock, which addresses the challenges of matching GraphQL queries due to their sensitivity to spaces and line breaks. This extension, now part of the official WireMock organization on GitHub, enhances WireMock's capability to semantically validate and match GraphQL queries, overcoming the limitations of WireMock's existing request body matching function. Hayashi explains that the extension allows for semantic verification by normalizing query spaces, making it easier to mock GraphQL APIs in end-to-end testing environments. The extension can be integrated into WireMock, including Docker instances, by adding the necessary JAR file, and its general availability is anticipated in the upcoming WireMock 4 release. With this development, Hayashi looks forward to feedback from GraphQL users to further improve this tool.
Sep 19, 2023
815 words in the original blog post.