<?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 Nimali Weerasooriya on Medium]]></title>
        <description><![CDATA[Stories by Nimali Weerasooriya on Medium]]></description>
        <link>https://medium.com/@nimali_wee?source=rss-d63f3675ab72------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*BDYn-Ab8xM03kNrNZXxiLg.jpeg</url>
            <title>Stories by Nimali Weerasooriya on Medium</title>
            <link>https://medium.com/@nimali_wee?source=rss-d63f3675ab72------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 11:19:32 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nimali_wee/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[Automation with TypeScript]]></title>
            <link>https://medium.com/tales-from-nimilandia/automation-with-typescript-f887aee25f74?source=rss-d63f3675ab72------2</link>
            <guid isPermaLink="false">https://medium.com/p/f887aee25f74</guid>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[qa-automation]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[typescript]]></category>
            <dc:creator><![CDATA[Nimali Weerasooriya]]></dc:creator>
            <pubDate>Tue, 30 Aug 2022 17:20:04 GMT</pubDate>
            <atom:updated>2022-08-30T17:20:04.017Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CgKsAIqyS9scrno_IfAuwg.png" /></figure><blockquote>A story of learning a new testing tool or new technology is a work of art that anyone would have to go through in making a difference in their career, which we look forward to accomplishing at our best. My personal story of learning TypeScript started at the mid-stage of my career where I was supposed to work on. I started with Selenium to do the test automation and moved to Cypress, then again moved to TypeScript as I was supposed to sharpen my knowledge through next-generation rising tools and never missed any chances to impress my own self with the widened area of knowledge that I was able to grasp which also made everything easier to learn and grow in my career ladder.</blockquote><h3><strong>TypeScript</strong></h3><p>TypeScript is an open-source programming language developed and maintained by Microsoft. It is a strict syntactical superset of JavaScript and adds optional static typing to the language. If you are aware of OOPS principles, TypeScript supports all OOPS concepts just like C# and Java. It is a typed superset, which means it provides an additional layer to JavaScript. So that it will be easy for developers coming from another programming background and know the OOPS concept.</p><p>TypeScript enables us to use stub and have a more agile approach for automation development.</p><h3><strong>What is TypeScript automation?</strong></h3><p>The ecosystem of JavaScript includes TypeScript. With static typing, classes, interfaces, and real-time IDE support, this language is a typed variant of JavaScript that compiles to it for further execution and aids in the development of clean code.</p><p>Static types give comprehensive documentation that makes it simple to comprehend and maintain old code, helping to prevent defects from sneaking into the code base due to human error. To create reliable applications, employ TypeScript’s static inspection and code refactoring features.</p><p><strong>Automation frameworks/tools that support TypeScript</strong></p><ul><li>Jest — it is still not 100% smooth and you might need to make some alterations based on your framework needs.</li><li>WebdriverIO</li><li>Selenium</li><li>Mocha</li><li>Protractor</li><li>Cucumber</li><li>Puppeteer</li></ul><p>In the initial state, I have configured TypeScript Automation Framework.</p><h4><strong>Step 1</strong>: Create a Project Folder</h4><p>The first step is to create a new folder on your computer in the desired location.</p><h4><strong>Step 2</strong>: Open Project Folder TypeScript in Visual Studio Code</h4><p>i. Open, Visual Studio Code, Click on File &gt; Open Folder</p><p>ii. Choose TypeScript Folder and Click on Select Folder at the bottom</p><h4><strong>Step 3</strong>: Create pacakge.json File</h4><p>Open Terminal, In Visual Studio Code by clicking on Terminal Menu &gt; Choose New Terminal.</p><p>Note: Ensure New Terminal is opened in the working directory as TypeScript.</p><p>i. New Terminal window appears at the bottom of Visual Studio Code, In the new terminal type the below command</p><p><strong><em>npm init</em></strong></p><p>ii. It will ask you a set of questions if you want, you can type the desired text, else hit [Enter] key one by one until you get the message<em> </em><strong><em>Is this Ok?</em></strong> then again hit enter it will create package.json for you.</p><h4><strong>Step 4</strong>: Install TypeScript Using the Below Command Typing in Terminal</h4><p><strong><em>npm i typescript</em></strong></p><h4><strong>Step 5: </strong>Create TypeScript Config<strong> </strong>File (tsconfig.json)</h4><p><strong><em>npx tsc –init</em></strong></p><h3><strong>How to install TypeScript?</strong></h3><p>It is easy to install, you just need to add it as a node-module. Open your command prompt simply type this command.</p><p><strong><em>npm install -g typescript</em></strong></p><p>Note: In order to install it, you need to have a node installed on your machine.</p><p>Verify the version once you installed it. You can use the command <strong><em>tsc -v</em></strong><em> </em>to verify.</p><p>If you don’t see the version output like the above, it means it is not installed.</p><h3><strong>How does TypeScript work?</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/822/1*z3Tk1L5qZxRp1dqsxbvVvw.jpeg" /></figure><p><strong>View of the Structure</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BKjz6MohwQckMJ02un8k8A.jpeg" /></figure><p>Understanding the basics helps you build a good automation framework. Now you know the basics of TypeScript, you can explore yourself and try various things. I highly recommend you to use the TypeScript playground using the link <a href="https://www.typescriptlang.org/play/index.html">https://www.typescriptlang.org/play/index.html</a></p><blockquote>I regularly conduct research on learning points in my capacity as a Quality Assurance Automation Engineer. I primarily watched YouTube courses and videos. Then, I continue to practice some exercises while watching the videos. I employed Visual Studio to create scripts. I ran the scripts I had divided out for different purposes to see the outcomes and any problems they had.</blockquote><blockquote>Aside from that, I also have documents in Confluence that cover the concept of overall testing and testing tools, as well as a book that I keep to keep track of some significant ideas and theories that I can quickly refer to.</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f887aee25f74" width="1" height="1" alt=""><hr><p><a href="https://medium.com/tales-from-nimilandia/automation-with-typescript-f887aee25f74">Automation with TypeScript</a> was originally published in <a href="https://medium.com/tales-from-nimilandia">Tales from Nimilandia</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>