<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Akshay Maldhure on Medium]]></title>
        <description><![CDATA[Stories by Akshay Maldhure on Medium]]></description>
        <link>https://medium.com/@akshaymaldhure?source=rss-a1707158f896------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*M6v9LazH1Kfo_r9ctXBX8g.png</url>
            <title>Stories by Akshay Maldhure on Medium</title>
            <link>https://medium.com/@akshaymaldhure?source=rss-a1707158f896------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 16 Nov 2026 21:56:53 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@akshaymaldhure/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Building a multi-pipeline CI setup for running automated tests in GitLab]]></title>
            <link>https://medium.com/gojekengineering/building-a-multi-pipeline-ci-setup-for-running-automated-tests-in-gitlab-106f7cf1f7b3?source=rss-a1707158f896------2</link>
            <guid isPermaLink="false">https://medium.com/p/106f7cf1f7b3</guid>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[gitlab]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[gojek]]></category>
            <dc:creator><![CDATA[Akshay Maldhure]]></dc:creator>
            <pubDate>Fri, 24 Feb 2023 07:25:45 GMT</pubDate>
            <atom:updated>2023-02-24T07:25:45.857Z</atom:updated>
            <content:encoded><![CDATA[<h4>Here’s a detailed view into setting up this process up for combining the development and the testing workflows.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ib60JTInUvP_tfqq1b7XGQ.jpeg" /></figure><p>Multi-pipeline CI (continuous integration) setup refers to the process of combining two or more different CI pipelines to create a single workflow.</p><p>This article explains how to set this process up for combining the development workflow (e.g. unit test → build → deploy) and the testing workflow (e.g. running functional tests from an independent and separate project in CI) into a single pipeline in <a href="https://about.gitlab.com/">GitLab</a>.</p><p>This is specifically useful in cases where the tests reside outside the application repository. Such a setup could also be enabled for more than one application within a given team by creating reusable CI templates.</p><h3>Rationale</h3><p>The process of combining the development and testing workflows lets us run the automated tests (that are typically built and maintained by the QAs/SDETs in the teams) <em>in conjunction with</em> every change made by the developer(s) to any of the applications rather than running those in a standalone/separate pipeline (e.g. <a href="https://docs.gitlab.com/ee/ci/pipelines/schedules.html">a scheduled pipeline</a>).</p><p>The idea of running tests only on application side changes could be more efficient and effective since it:</p><ol><li>Makes it possible to segregate, track, debug, and fix the test failures on a per-application side change basis.</li><li>Helps ensure more optimal utilization of the CI resources.</li></ol><h3>Pipeline sample</h3><p>As seen in the video below, the stages pre_deploy test build deploy_integration deploy_production and post_deploy belong to the development workflow (application project); whereas the stage functional_test belongs to the testing workflow (test project).</p><p>In this example, it can be seen that we have combined two different pipelines; a pipeline from the application project and a pipeline from the testing project so that the result looks like a single pipeline below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*wB0afNFH0YYTSRtd8Om6ng.gif" /><figcaption>A sample multi-pipeline from an application project comprising the development and testing workflows running together on a developer MR on that application project.</figcaption></figure><h3>Implementation</h3><p>This setup is a combination of the following pieces coming together.</p><h4><strong>CI config in the test project (downstream)</strong></h4><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/3610f5b2b6e2698cdcb3c8da5c8c8c9a/href">https://medium.com/media/3610f5b2b6e2698cdcb3c8da5c8c8c9a/href</a></iframe><p>This config defines what the downstream pipeline (i.e. the functional testing pipeline) should do using the script keyword. We’ve defined a bunch of rules that define the applicability of the test job based on the pipeline source, project code, and job name coming from the upstream pipeline (via CI templates).</p><h4><strong>CI templates</strong></h4><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4831bcdb4b5fdb1d4a358634ceb8db6e/href">https://medium.com/media/4831bcdb4b5fdb1d4a358634ceb8db6e/href</a></iframe><p>This project defines a bunch of reusable test job templates that could be used in the CI configs of all applications in your team. By having a standard naming convention for the integration deployment job for every application pipeline, it becomes possible to make the test job <em>depend</em> upon the integration deployment job using the needs keyword. We could also use some more keywords like allow_failure (with the value false to disallow merging the MRs on functional test failures) and resource_group (with the value same as that in the integration deployment job to ensure that a pipeline does not overwrite the integration deployment or run the tests while the integration deployment or tests from some other pipeline are running).</p><h4>CI config in application/service (upstream)</h4><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0321858ee7a9292d259c17812bcc3567/href">https://medium.com/media/0321858ee7a9292d259c17812bcc3567/href</a></iframe><p>This project simply <em>imports</em> the jobs defined in ci-templates using the include keyword. No extra information is passed here since the downstream already defines all of that.</p><p>This is how the downstream pipeline defined in the test project with the job definitions from CI templates gets connected to the upstream pipeline defined in the application/service to form a single multi-pipeline setup.</p><p>Happy testing, folks!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IPWwoozDxeKoXMtXEyrtLw.png" /></figure><p>To check out more stories from our vault, click <a href="https://www.gojek.io/blog">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=106f7cf1f7b3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/gojekengineering/building-a-multi-pipeline-ci-setup-for-running-automated-tests-in-gitlab-106f7cf1f7b3">Building a multi-pipeline CI setup for running automated tests in GitLab</a> was originally published in <a href="https://medium.com/gojekengineering">Gojek Product + Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Managing the test data for functional tests]]></title>
            <link>https://medium.com/circleslife/managing-the-test-data-for-functional-tests-7f299aae2957?source=rss-a1707158f896------2</link>
            <guid isPermaLink="false">https://medium.com/p/7f299aae2957</guid>
            <category><![CDATA[test-data-management]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-testing]]></category>
            <dc:creator><![CDATA[Akshay Maldhure]]></dc:creator>
            <pubDate>Wed, 09 Dec 2020 10:01:49 GMT</pubDate>
            <atom:updated>2020-12-09T13:45:07.206Z</atom:updated>
            <content:encoded><![CDATA[<h3>Background</h3><p>Most functional tests need test data to work. Consider this classic example of an end-to-end login test for an application in a “testing” environment, where the application services are typically configured to talk to a real database system. We need to provide the credentials of a user for such a test. So our test flow should either <em>create</em> a user or <em>use</em> an existing one. This is where accessing and managing the test data comes into picture.</p><p>This article talks about one of the ways of de-tangling the test data dependency and management part from the tests.</p><h3>Problem</h3><p>The task of creating, accessing and managing the test data during test execution has below challenges.</p><ol><li>Unavailability of a data mocking system: You need to rely on one or more “real” downstream systems for data creation.</li><li>Complexity in creating new data: No straightforward way of creating data (e.g. lack of APIs, multiple systems needing updates after data creation, etc).</li><li>The state of test data matters for the tests: The test data may not be re-usable if we are unable to reset its state after test execution.</li><li>Resilience: Some system(s) might fail to create new test data.</li></ol><h3>Approach</h3><p>In order to address this problem, we came up with an approach of storing the test data in a centralised data store, which was used by our automation suites for any test data needs during test execution.</p><p><strong>We achieved this by building a test data management system (TDMS) that uses an Elasticsearch instance as a data store.</strong></p><p>In the application testing process, there are a set of test cases that aim at validating the test generation flows. We leveraged such tests to seed our data store with newly generated test data in a specific format (schema) either through automation test hooks or through cron (maintenance) jobs.</p><p>So going back to our original example of a login test, the most fundamental data entity could be a user. So we could choose to store the test data on a corresponding Elasticsearch index called “user”, in which documents look like below.</p><pre>{<br> &quot;id&quot;: 1,<br> &quot;personalDetails&quot;: {<br> &quot;firstName&quot;: &quot;John&quot;,<br> &quot;lastName&quot;: &quot;Doe&quot;,<br> &quot;age&quot;: 28<br> },<br> &quot;accountStatus&quot;: &quot;active&quot;<br>},<br>{<br> &quot;id&quot;: 2,<br> &quot;personalDetails&quot;: {<br> &quot;firstName&quot;: &quot;Stephen&quot;,<br> &quot;lastName&quot;: &quot;Williams&quot;,<br> &quot;age&quot;: 30<br> },<br> &quot;accountStatus&quot;: &quot;suspended&quot;<br>}</pre><p>Now we can have the tests query TDMS for the data as per the requirement. For example, <em>get an active user for testing login success</em> <strong>or</strong> <em>get a suspended user for testing login failure</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/771/1*lx021XfGo7SEiaL6oaJrMQ.png" /><figcaption>A test data management system showing the flow of test data with the application under test</figcaption></figure><p>However, there are a couple of problems with this approach.</p><ol><li>The test data state will not be updated in TDMS after test execution.</li><li>Multiple tests are likely to end up using the same test data during execution.</li></ol><p>In order to address these problems, we added a data lock mechanism to prevent this from happening. Once the data is locked, no other tests can reuse the data set until the data is refreshed in TDMS.</p><h3>Future plans</h3><p>While this approach has solved our burning problem of managing the test data, we have plans to overcome some of the shortcomings and make it as a holistic system useful for the entire organisation by:</p><ol><li>Having real-time data refresh/updates so that more data is available immediately after consumption.</li><li>Building a UI tool to filter and access the test data so that anyone can fetch the data based on their testing requirements.</li><li>Ensuring we have enough test data to serve all the test scenarios as some tests might invalidate/terminate the data points permanently.</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7f299aae2957" width="1" height="1" alt=""><hr><p><a href="https://medium.com/circleslife/managing-the-test-data-for-functional-tests-7f299aae2957">Managing the test data for functional tests</a> was originally published in <a href="https://medium.com/circleslife">Circles.Life</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How I ended up testing Kafka integrations using API tests]]></title>
            <link>https://medium.com/swlh/how-i-ended-up-testing-kafka-integrations-using-api-tests-f4731ef819b2?source=rss-a1707158f896------2</link>
            <guid isPermaLink="false">https://medium.com/p/f4731ef819b2</guid>
            <category><![CDATA[redis]]></category>
            <category><![CDATA[apache]]></category>
            <category><![CDATA[integration-testing]]></category>
            <category><![CDATA[stream-processing]]></category>
            <category><![CDATA[kafka]]></category>
            <dc:creator><![CDATA[Akshay Maldhure]]></dc:creator>
            <pubDate>Fri, 28 Jun 2019 14:30:27 GMT</pubDate>
            <atom:updated>2019-07-05T06:47:38.335Z</atom:updated>
            <content:encoded><![CDATA[<p>As a Quality Analyst, I build software testing systems, write tests and write more tests.</p><p>If you’re interested in knowing how I discovered the value of my API tests for testing the API integrations with an internal <a href="https://kafka.apache.org/">Apache Kafka</a> system, read on.</p><h3>About Kafka</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/975/1*8GbrXbHdH5uPGMb5epWhrg.png" /><figcaption>Image: https://kafka.apache.org</figcaption></figure><p>As per this <a href="https://kafka.apache.org/intro">introduction page</a>, Apache Kafka® is a distributed <a href="https://en.wikipedia.org/wiki/Publish%E2%80%93subscribe_pattern">publish-subscribe</a> streaming platform that can be used as a messaging system, a storage system, or a stream processing system in enterprise applications.</p><p>In the case of my application, Kafka is used as an event/messaging system that would enable the application APIs to publish and subscribe to various events in the categories of records called “topics”.</p><h3>Stream processing in action</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/766/1*uk9vsJaKpNuYkUYnlOQHGA.png" /></figure><p>My application under test has got a social media section inside it (consider something like <a href="http://facebook.com/"><em>Facebook</em></a>) and the application backend has got a <strong><em>feedservice</em></strong> that has got some REST endpoints that would facilitate creating, editing and deleting the posts and comments, reacting to the posts and comments with common actions like “like”, “unlike”, “report as inappropriate”, etc. There’s another service called <strong><em>userservice</em></strong> that populates some statistics like postsCount,commentsCount, likesReceived, likesGiven, etc. pertaining to the social media profile of a user.</p><blockquote><em>What’s interesting here is to know how the </em>userservice<em> gets to know about various statistical numbers based on the happenings with the </em>feedservice<em> for a given user. Well, this is where Kafka comes into the picture. Various </em>feedservice<em> actions “publish” their activities to Redis for independent and asynchronous handling of events which are eventually pushed under the categories of records called “topics” in Kafka which are “consumed” by the </em>userservice<em>. It is worth noting that a given consumer could listen to </em><strong><em>one or more</em></strong><em> “topics”.</em></blockquote><blockquote><em>One can think of the </em>feedservice<em> as an FM radio broadcaster, the </em>userservice<em> as a human listener and Kafka as the broadcasting cluster.</em></blockquote><h3>My testing system and test cases</h3><p>I built an API testing system that tests the <em>feedservice</em> and <em>userservice</em> APIs <strong>in conjunction with each other </strong>in a below-mentioned manner.</p><p>For example, consider some test cases like:</p><p>As a user with userId = 1:</p><ol><li>When I create a post using a POST call to the <em>feedservice/create/</em> API successfully, the postsCount in my profile should be incremented by 1 (validate this by asserting the response from the <em>userservice/profile/1</em> API).</li><li>When I comment on a post using a POST call to the <em>feedservice/create/</em> API successfully, the commentsCount in my profile should be incremented by 1 (validate this by asserting the response from the <em>userservice/profile/1</em> API).</li><li>When I receive a “like” from some other profile user using a PUT call to the <em>feedservice/action/</em> API successfully, then likesReceived in my profile should be incremented by 1 (validate this by asserting the response from the <em>userservice/profile/1</em> API).</li><li>When I “like” someone else’s post or comment using a PUT call to the <em>feedservice/action/ </em>API successfully, the likesGiven in my profile should be incremented by 1 (validate this by asserting the response from the <em>userservice/profile/1</em> API).</li><li>When I delete my post using a DELETE call to the <em>feedservice/post/&lt;postId&gt;, </em>the postsCount, commentsCount, likesReceived should be reverted to their original counts.</li></ol><p>(of course with some assumptions like I store the initial counts from my profile in the setup() of my test suite, no other system does any interactions on this environment with my user while my tests are running, etc.)</p><p>… and so on.</p><blockquote><em>Something that’s worth noticing here is that I’m not just testing the core functionality of the </em>feedservice<em> and </em>userservice<em> APIs, but also validating that the numbers/counts reflected in the data provided by the </em>userservice<em> are correct</em><strong><em> as per the actions accomplished</em></strong><em> using the </em>feedservice<em>. This is like testing higher-level integrations between these APIs.</em></blockquote><p>An ideal way of achieving this would be to have a set of integration tests that would validate the integration between the business APIs (<em>feedservice</em> and <em>userservice</em>) and Kafka APIs, but since nothing of that sort existed in my project, I chose the “REST API way” to test it. The tests didn’t take much time to write but turned out to be a great help for the continuous testing of some of the critical end-user scenarios.</p><p>Do you believe a testing strategy like this makes sense? Thoughts? Feedback? Feel free to share.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f4731ef819b2" width="1" height="1" alt=""><hr><p><a href="https://medium.com/swlh/how-i-ended-up-testing-kafka-integrations-using-api-tests-f4731ef819b2">How I ended up testing Kafka integrations using API tests</a> was originally published in <a href="https://medium.com/swlh">The Startup</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Data-driven migration testing with REST APIs and Python]]></title>
            <link>https://medium.com/quick-code/data-driven-migration-testing-with-rest-apis-and-python-4585fb13b23f?source=rss-a1707158f896------2</link>
            <guid isPermaLink="false">https://medium.com/p/4585fb13b23f</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[migration-test-approach]]></category>
            <category><![CDATA[data-driven-testing]]></category>
            <category><![CDATA[data-migration-testing]]></category>
            <category><![CDATA[data-migration]]></category>
            <dc:creator><![CDATA[Akshay Maldhure]]></dc:creator>
            <pubDate>Mon, 27 May 2019 06:49:31 GMT</pubDate>
            <atom:updated>2019-05-31T17:56:55.124Z</atom:updated>
            <content:encoded><![CDATA[<p>Data migration is the process of transferring information (data) from one system to a new system.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*mNUAms4XoRHJi6iUVuHpHA.png" /><figcaption>Image courtesy: <a href="https://www.cobalt.net/">https://www.cobalt.net</a></figcaption></figure><h4>Background</h4><p>After migrating the data by running the migration scripts on a database, it is important to ensure that the migrated data lands “correctly” into the database, especially in cases where the correctness of data is the top concern and any issues with this data could be expensive, e.g. transactional records involving valuable data, sensitive information, data derived from the migrated data based on some complex business logic, etc.</p><h4>Problem Statement</h4><p>Consider this simple example where we intend to migrate the data from multiple CSV files to the database, the data from which gets massaged at the API layer in a bank account management system. This system has different users with distinct phone numbers.</p><p>Here, we have two CSVs (<em>users.csv </em>containing the primary details of the bank account holders and <em>user_account_details.csv</em> containing the details of the balance and bonus amounts for different users in their respective accounts). In a real world scenario, there could be much more such CSV files. In fact, there could be another database(s) instead of the CSVs altogether.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/861/1*RgOs3b0eQ3CQXPZs4dDXFg.png" /></figure><p>As mentioned earlier, it is essential to ensure this data lands “correctly” into the database. <strong>As such, testing the migration scripts along with the business logic in the API layer becomes important.</strong> Since the correctness of the actual data is the top concern here, merely doing some simple tests like asserting on the count of the migrated data records against that of the reference data records from CSV may not be sufficient (in fact, it won’t be!).</p><h4>Approach</h4><p>So I used the <a href="https://en.wikipedia.org/wiki/Data-driven_testing">data-driven testing</a> capabilities of a test framework/runner like <a href="http://docs.lemoncheesecake.io/en/latest/ddt.html"><em>lemoncheesecake</em></a> with the Python programming language. There would be a <a href="http://docs.lemoncheesecake.io/en/latest/tests-and-suites.html"><em>lemoncheesecake</em></a> test suite that would have parameterised test(s) that would run over different records from a reference CSV (this CSV may essentially be the same file which was fed to the migration scripts for migrating the data) and validate different data points by making the actual relevant REST API calls.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jt6jA1I-cHDrhZWp4JwA0w.png" /></figure><p>Here’s how the test suite looks like. Of course, there would be many more validations that could be achieved by asserting the values from the returned API responses in the real world.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6d23fda76516fbb482251209baa00e7a/href">https://medium.com/media/6d23fda76516fbb482251209baa00e7a/href</a></iframe><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4585fb13b23f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/quick-code/data-driven-migration-testing-with-rest-apis-and-python-4585fb13b23f">Data-driven migration testing with REST APIs and Python</a> was originally published in <a href="https://medium.com/quick-code">Quick Code</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[As a QA, this is how I used the Event Store]]></title>
            <link>https://medium.com/swlh/as-a-qa-this-is-how-i-used-the-event-store-2bb028c5ccf8?source=rss-a1707158f896------2</link>
            <guid isPermaLink="false">https://medium.com/p/2bb028c5ccf8</guid>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[event-processing]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[mocha]]></category>
            <category><![CDATA[eventstore]]></category>
            <dc:creator><![CDATA[Akshay Maldhure]]></dc:creator>
            <pubDate>Mon, 06 May 2019 11:34:59 GMT</pubDate>
            <atom:updated>2019-06-18T09:57:48.887Z</atom:updated>
            <content:encoded><![CDATA[<h3>As a QA, this is how I used the Event Store in end-to-end tests</h3><p>In a truly end-to-end test automation strategy that includes validations at multiple layers through various components of a system where a QA Engineer might want to explore beyond the conventional UI and API test strategies, it is important to dig deeper into the system in order to access and test some specific aspects of an event sourcing system like the <a href="https://eventstore.org/">Event Store</a>. This aspect becomes significant in data-oriented projects; especially when I, as a QA, care about testing the flow and integrity of the test data from an end-to-end perspective, i.e. starting right from the data input source all the way till the APIs and eventually the UI.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5aK8DY1KOtzRpqE4ahTbRQ.png" /></figure><p>For instance, consider a part of a project that deals with the flow of data in below manner.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*q-3iTTfvBs2l0U8pYZchiw.png" /></figure><blockquote>Here, it is important to note that the Event Store is responsible to process the sourced events, extract and process the data contained in the events and feed the same to an event post-processing component, which would eventually populate another database (say, <a href="https://www.mongodb.com/">MongoDB</a>) with the processed data, which would eventually be massaged at the API layer and shown on the UI.</blockquote><blockquote>So the question is, how do I ensure that the data has been processed by the Event Store successfully and passed to the event post-processor?</blockquote><p>Well, I did it through two steps, i.e. <strong>ensure there are no</strong>:</p><ol><li><strong>In-flight events</strong></li><li><strong>Parked events</strong></li></ol><blockquote>I used the Event Store’s <em>subscriptions/</em> API endpoint for this purpose, like illustrated in the <em>Node.js mocha</em> test specs below.</blockquote><h3>In-flight events</h3><p>In this case, I hit the <em>subscriptions/ </em>endpoint and check for the attribute totalInFlightMessages in the API response and ensure it is equal to 0; if not, we retry for a maximum of 5 times before we mark the test spec as “failed”.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/583fbf473a07f28b20ca7e56ab18db3f/href">https://medium.com/media/583fbf473a07f28b20ca7e56ab18db3f/href</a></iframe><h3>Parked events</h3><p>Once we have checked there are no in-flight events, we can now safely check for the parked events using the same <em>subscriptions/</em> API.</p><p>In this case, we hit the <em>subscriptions/</em> endpoint, store the resultant JSON array in a Javascript array, hit each of the parkedMessageUri links from the array and ensure that the response code in each case is 404 since the same corresponds to the fact that there are no parked events in each of the “subscriptions”.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7ad0296d697746c28ff9a0be8fba23b1/href">https://medium.com/media/7ad0296d697746c28ff9a0be8fba23b1/href</a></iframe><h3>Conclusion</h3><p>One can use the test specs like the ones mentioned above in an end-to-end CI test pipeline in order to ensure there are no in-flight and parked events as pre-requisites before performing any validations in the later components in the project.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2bb028c5ccf8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/swlh/as-a-qa-this-is-how-i-used-the-event-store-2bb028c5ccf8">As a QA, this is how I used the Event Store</a> was originally published in <a href="https://medium.com/swlh">The Startup</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>