<?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 Ania Duldiier on Medium]]></title>
        <description><![CDATA[Stories by Ania Duldiier on Medium]]></description>
        <link>https://medium.com/@annaduldiier?source=rss-5f85bfe99e7a------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*nY6t8KwdyczG5l0g.</url>
            <title>Stories by Ania Duldiier on Medium</title>
            <link>https://medium.com/@annaduldiier?source=rss-5f85bfe99e7a------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 06:45:59 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@annaduldiier/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[Trykhaty kite festival in Ukraine]]></title>
            <link>https://annaduldiier.medium.com/trykhaty-kite-festival-in-ukraine-2766cfb6e9aa?source=rss-5f85bfe99e7a------2</link>
            <guid isPermaLink="false">https://medium.com/p/2766cfb6e9aa</guid>
            <category><![CDATA[kitefestival]]></category>
            <category><![CDATA[traveling]]></category>
            <category><![CDATA[kites]]></category>
            <category><![CDATA[ukraine]]></category>
            <dc:creator><![CDATA[Ania Duldiier]]></dc:creator>
            <pubDate>Tue, 24 Aug 2021 17:39:24 GMT</pubDate>
            <atom:updated>2021-08-24T19:47:27.594Z</atom:updated>
            <content:encoded><![CDATA[<p>Wind, kites, festival life, traveling alone in Ukraine and ending up in the middle of nowhere</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TP2NAGm9f70bI30G8t_6vA.jpeg" /><figcaption>Kites on Trykhaty festival, photo by Serhii Konononenko</figcaption></figure><p>This year I got really inspired by the giant inflatable kites and from now on my biggest dream is to create the giant kite myself, so this is how the wind brought me to the small marvellous village in the South of Ukraine. It was not so easy to get here because the roads in this region of Ukraine are particularly awful, but I think it’s the case when you are heading to the middle of nowhere.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iH5KVEpi68XukyUUmxdfYg.jpeg" /><figcaption>Southern Bug river in Trykhaty village, photo by Serhii Konononenko</figcaption></figure><p>By far the Trykhaty kite festival is the biggest kite festival in Ukraine. And both Ukrainian and foreign teams of kiters come annually here to show their kites. This year due to coronavirus there were only three foreign teams from Turkey, Estonia, and Scotland.</p><p>I stayed at the festival for two days and all this time I spent in the kiters camping, so there will be some insider information following 😱</p><p>So, first of all, nowadays there is a vast variety of kites in all imaginable designs and colors. So there are up to dozen different categories of kites. But personally, I divide them into three:</p><ul><li>flat kites that we are all used to</li><li>giant inflatable kites that are relatively new to the kiting history</li><li>and finally maneuvered kites (like parafoils and others)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OBdYeakBT62AkKfws9VMtw.jpeg" /><figcaption>Giant alien kite from Peter Lynn, photo by Serhii Kononenko</figcaption></figure><p>No need to say that the most impressive and spectacular kites are the giant inflatable kites. These kites are also called display kites because they need an additional kite, called pilot or lift kite, to hold them up in the air. The main figure behind these kites is <a href="https://en.wikipedia.org/wiki/Peter_Lynn">Peter Lynn</a>, inventor and kitemaker from New Zealand. By the way, this year <a href="https://www.facebook.com/TUGdotCOM?__tn__=-UC*F">Andrew Beattie</a> from Scotland brought kites created by Peter Lynn.</p><p>Now as we’ve talked a little bit about the kites themselves, let’s talk about the kiters. There are two major categories of kiters: those that manufacture the kites themselves and then fly them on festivals, and also those who once bought kites and now they travel all over the world with those kites, visiting different kite festivals.</p><p>The most interesting thing about the kites is that this is not such a safe hobby and don’t be fooled by these colorful sky floating photos reminiscent of some childhood memories.</p><p>First of all, don’t run through the fields where the kites are, cause kites are held on ropes and when the wind is low the ropes can go down and that increases your chances of stumbling over them. Also, don’t underestimate the lifting power of the wind. The wind at the festival was relatively low for me, not even merely close to one of those mild winds that you feel near the sea, but somehow <strong>one of the kites lifted a big concrete anchor block</strong> that it was attached to.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*F0nY1KaSBvFuT_Gdt0J9OQ.jpeg" /><figcaption>The concrete block that was dragged on the ground and put on top of the kiters bag by the power of wind, photo by Andrew Beattie</figcaption></figure><p>Also as one of the Ukrainian kiters told me, that last year they also had an accident with a bottle of water falling from the height, because it was attached to the flag on the kite and was used as an anchor to hold the flag vertically in the sky. So if there is a fence around the territory where the kites are anchored please be sure that it is for a good reason.</p><p>To sum up, I was fascinated by the nature of Trykhaty village even though it’s a pity that you can’t swim there, the kites and the kiters culture and their “floating” lifestyle really blew my mind. Will definitely come again.</p><p>P.S. don’t forget the sun protection cause the sun is really burning and there are a few shadows around. So in the end here is the video of me learning how to joggle under the giant flying alien.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FP3ky_aGYSEo&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DP3ky_aGYSEo&amp;image=http%3A%2F%2Fi.ytimg.com%2Fvi%2FP3ky_aGYSEo%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/3369eeb0d73ae387240eb8d049906da6/href">https://medium.com/media/3369eeb0d73ae387240eb8d049906da6/href</a></iframe><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2766cfb6e9aa" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Simple Selenium Test Automation Project in Java With Page Object Model]]></title>
            <link>https://medium.com/swlh/simple-selenium-test-automation-project-in-java-with-page-object-model-a18d5f5dd35?source=rss-5f85bfe99e7a------2</link>
            <guid isPermaLink="false">https://medium.com/p/a18d5f5dd35</guid>
            <category><![CDATA[pagefactory]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[test-automation]]></category>
            <category><![CDATA[selenium]]></category>
            <category><![CDATA[page-object-model]]></category>
            <dc:creator><![CDATA[Ania Duldiier]]></dc:creator>
            <pubDate>Thu, 15 Oct 2020 12:19:26 GMT</pubDate>
            <atom:updated>2020-10-28T12:30:38.020Z</atom:updated>
            <content:encoded><![CDATA[<p>How to optimize your tests using the Page Object Model.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*U0pBUjfNav7vDyqq" /><figcaption>Photo by <a href="https://unsplash.com/@barkiple?utm_source=medium&amp;utm_medium=referral">John Barkiple</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>What is PageObject?</h3><p><strong>Page Object Model </strong>is an object design pattern, in which for every web page in the application, there should be a relevant page<strong> class</strong>, various elements on the page are defined as <strong>variables</strong> on the class. To interact with different elements of web page <strong>methods</strong> are implemented in the class.</p><pre><strong>public class </strong>HomePage {<br>  <br>   <strong>//Variables</strong><em><br>    </em>@FindBy(xpath = &quot;xpath&quot;)<br>    private WebElement signInButton;</pre><pre><em>    </em>@FindBy(xpath = &quot;xpath&quot;)<br>    private WebElement userAvatar;</pre><pre>  <strong> //Methods</strong><br>    <strong>public void </strong>clickSignInButton() {<br>        <strong>signInButton</strong>.click();<br>    }</pre><p><strong>Why should we use the Page Object Model?</strong></p><blockquote>So now with every change on a webpage, we have to change the code of our tests only in one place.</blockquote><p>Can you imagine changing one element on a web page that 10 or 100 tests depend on? That is a time-consuming work that increases the cost of code maintenance and it is a great obstacle for implementing automated tests in the early stages of any agile project.</p><p>Basically, Page Object is a way to separate the webpage description<strong> (locators) </strong>and test logic. So now with every change on a webpage, we have to change the code of our tests only in one place.</p><p>Let’s take a look at the <strong>advantages </strong>of using the PageObject Model.</p><ul><li>Our tests are separated from locators, that reduces code duplication significantly and helps keep code clean.</li><li>Due to well-named methods in classes, code is easy to read and to maintain.</li><li>Tests are more concise because we are using existing methods of page object classes.</li><li>Any changes in the webpage can easily be implemented, in one place, that is in our Page Object Class.</li></ul><h3>Getting Ready</h3><p>To create a Page Object Model of our website, first of all, we create a class in our automation framework to represent the corresponding page of our application.</p><pre>public class HomePage{<br>}</pre><p>The value of class variables are, in fact, locators to the elements on the actual web page. After defining these locators in page object classes, there is no need to hardcode them every time we use them in tests.</p><pre>By signinButton = By.xpath<strong>(</strong>&quot;//a[@class=&#39;HeaderMenu-link no-underline mr-3&#39;]&quot;<strong>);</strong></pre><p>There are different types of locators: <strong>ID</strong>, <strong>Name</strong>, <strong>ClassName</strong>, <strong>CSS</strong>, <strong>XPath</strong>. In this tutorial, we will use <strong>XPath</strong>s as locators. Read more about XPath <a href="https://www.w3schools.com/xml/xpath_syntax.asp">here</a>.</p><p>Now that we’ve defined our variables we can create methods to interact with them.</p><pre>public void clickSigninButton();<br>public void signIn(String usersEmail, String password);</pre><p>It is a good practice to write convenience methods. For example, to log into the account we need to call three different methods(set user email, set user password, click on Join), so it’s a good idea to unite all these actions in one method.</p><pre>public void signIn(String usersEmail, String password) {<br>    setUserEmail(usersEmail);<br>    setUserPassword(password);<br>    clikOnSubmit();<br>}</pre><p><strong>What is PageFactory?</strong></p><p>Page Factory in Selenium is an inbuilt Page Object Model concept for Selenium WebDriver. It is used for the initialization of the Page object. It is also used to initialize Page class elements without using the findElement() method.</p><p>Here is how our code would look like without using PageFactory:</p><pre>By signinButton = By.xpath<strong>(</strong>&quot;//a[@class=&#39;HeaderMenu-link no-underline mr-3&#39;]&quot;<strong>);</strong></pre><pre>public void clickSignInButton() {<br>driver.findElement(signInButton).click();<br>}</pre><p>Instead, with the help of the PageFactory class, we use annotations @FindBy to find WebElement.</p><pre>@FindBy(xpath = &quot;//a[@class=&#39;HeaderMenu-link no-underline mr-3&#39;]&quot;)<br>private WebElement signInButton;</pre><p>And then we use the <em>initElements</em> () method on PageFactory.</p><pre>LoginPage page = PageFactory.intElements(driver,LoginPage.<strong>class</strong>)</pre><p>Or, inside the web page class constructor:</p><pre>public LoginPage(WebDriver driver) {           <br>         this.driver = driver; <br>         PageFactory.initElements(driver, this);<br>}</pre><p>Page Factory will initialize every <em>WebElement</em> variable with @ FindBy annotation.</p><p><strong>Checkboxes and Toggles and RadioButtons</strong></p><p>To work with checkboxes, toggles, or radio buttons, instead of blindly clicking on them, it’s better to check their status first. To do that use isSelected() method.</p><pre>public void checkCheckbox(){<br>if(!checkBox.isSelected){<br>checkBox.click<br>}<br>}</pre><h3>Simple Selenium Test Automation Project in Java</h3><p>For the purpose of our Page Object Model tutorial, let’s automate sign in for GitHub. To do that, we need to automate the following steps:</p><p><strong>1.</strong>Go to <a href="https://github.com/">https://github.com</a></p><p><strong>2. </strong>Click on the Sign In button</p><p><strong>3.</strong> Fill out email and password</p><p><strong>4.</strong> Click on Sign In Button</p><h3>Setting Up the Project</h3><p>To separate the logic of tests and our page object classes we will put them in different folders.</p><h3>Homepage</h3><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6204f6b0278b4c63685f1f4172edfd4d/href">https://medium.com/media/6204f6b0278b4c63685f1f4172edfd4d/href</a></iframe><h3>SignIn Page</h3><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7839b5653273f13bedbd68aff2fa8e44/href">https://medium.com/media/7839b5653273f13bedbd68aff2fa8e44/href</a></iframe><h3>Running Tests</h3><p>Now to check whether sign-in functionality works correctly on GitHub we will write a few unit tests.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/774d53292093a0319a0dd533abe5b237/href">https://medium.com/media/774d53292093a0319a0dd533abe5b237/href</a></iframe><p>Now, imagine that we want to change our signIn() method inside SignInPage class. For example, we want to check whether the page loaded ( using isPageOpened() method) before filling the email and password fields.</p><pre><strong>public void </strong>signIn(String usersEmail, String password) {<br>    <strong>if </strong>(isPageOpened()) {<br>        setUserEmail(usersEmail);<br>        setUserPassword(password);<br>        clickOnSubmit();<br>    }<br>}</pre><p>So if we change our method like that, it will not affect the result of our test.</p><h3>Conclusion</h3><p>Page Object Model and Page Factory make it easy to model web pages in Selenium and test them automatically.</p><p>Note that Xpaths of web elements can change from build to build. That’s why the Xpaths of web elements for GitHub, that are provided in this tutorial can change in the near future. So always be careful with locators and Happy Testing!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a18d5f5dd35" width="1" height="1" alt=""><hr><p><a href="https://medium.com/swlh/simple-selenium-test-automation-project-in-java-with-page-object-model-a18d5f5dd35">Simple Selenium Test Automation Project in Java With Page Object Model</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[AssertJ vs JUnit]]></title>
            <link>https://annaduldiier.medium.com/assertj-vs-junit-483b7d6dc997?source=rss-5f85bfe99e7a------2</link>
            <guid isPermaLink="false">https://medium.com/p/483b7d6dc997</guid>
            <category><![CDATA[qa]]></category>
            <category><![CDATA[assertions]]></category>
            <category><![CDATA[junit]]></category>
            <category><![CDATA[assertj]]></category>
            <category><![CDATA[testing-tools]]></category>
            <dc:creator><![CDATA[Ania Duldiier]]></dc:creator>
            <pubDate>Thu, 20 Aug 2020 01:00:31 GMT</pubDate>
            <atom:updated>2020-08-25T03:25:44.774Z</atom:updated>
            <content:encoded><![CDATA[<h4>Use AssertJ for fluent and more readable assertions.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OTYXrS3yxEXTynPmllZjHw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@the_roaming_platypus?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">timJ</a> on <a href="https://unsplash.com/s/photos/singapore-architecture?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><h3><strong>What’s the difference between JUnit and AssertJ</strong></h3><p>Hi, there!</p><p>First of all, JUnit is an automated test framework that is built in Java, whereas AssertJ is an opensource library used for writing fluent and rich assertions in Java tests.</p><p>It’s true that you can write assertions just using JUnit, but if you ever have an extra half an hour for studying AssertJ, be sure to go for it. It will make your working process more effective and your code more readable.</p><h3><strong>Why should I use AssertJ?</strong></h3><ul><li><strong>easy to learn:</strong> Ready to dive in AssertJ? You can find all about AssertJ <a href="https://assertj.github.io/doc/">here</a>.</li></ul><blockquote><em>Took me less than half an hour to get AssertJ</em>.</blockquote><ul><li><strong>easy to use: </strong>you just need to add a dependency and static import in your test class to start using AssertJ.</li><li><strong>fluent</strong>: AssertJ helps you to diversify your assertions.</li><li><strong>more readable code</strong></li><li><strong>auto-completion: AssertJ </strong>provides auto-completion in IDEs. So you don&#39;t need to remember all method names.</li></ul><p>To start with AssertJ let’s add a dependency. Here is a <strong>Maven dependency:</strong></p><pre>&lt;dependency&gt;<br>    &lt;groupId&gt;org.assertj&lt;/groupId&gt;<br>    &lt;artifactId&gt;assertj-core&lt;/artifactId&gt;<br>    &lt;version&gt;3.16.1&lt;/version&gt;<br>    &lt;scope&gt;test&lt;/scope&gt;<br>&lt;/dependency&gt;</pre><p>And <strong>Gradle dependency:</strong></p><pre>testImplementation &#39;org.assertj:assertj-core:3.13.2&#39;<br></pre><p>Find the latest versions <a href="https://assertj.github.io/doc/">here</a>. After that add a static import to your test class.</p><pre>import static org.assertj.core.api.Assertions.*;</pre><h3>AssertJ in Action</h3><p>Now let’s have a look at some code examples comparing JUnit and AssertJ assertions. Starting with assertEquals assertion. Here is how we usually do this in JUnit.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/a2a08cc905cdbabda98a4171f6f039e7/href">https://medium.com/media/a2a08cc905cdbabda98a4171f6f039e7/href</a></iframe><p>An here is AssertJ way. The main difference is that we put an object we want to compare first and then our assertion.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/90f385e85dd09e6aa292dd3ac69b68a3/href">https://medium.com/media/90f385e85dd09e6aa292dd3ac69b68a3/href</a></iframe><p>The main benefit of AssertJ is that it is set up to provide auto-completion in IDEs. Once you have specified the object you want to compare (using assertThat):</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PXRfo4JnJXm15rbERfEJeg.png" /></figure><p>the IDE will understand the type of the comparison (in this case Object) and will show you all available assertions.</p><p>Also, it is often useful to describe the assertion performed, in AssertJ we can set the <strong>error message </strong>using</p><pre>.as(String description)</pre><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c1c70e6d9e4e4ff72e53fbdee52dda06/href">https://medium.com/media/c1c70e6d9e4e4ff72e53fbdee52dda06/href</a></iframe><h3>Testing Collections</h3><p>Here I will show just one example of using AssertJ when working with Collections. Here we are testing the TolkienCharacter class.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/db5eafc6830f046150e06b6d4a814aa0/href">https://medium.com/media/db5eafc6830f046150e06b6d4a814aa0/href</a></iframe><p>I used stream API and lambdas for writing tests using only JUnit.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/185f8cc836df52ac7c5daf825e183b44/href">https://medium.com/media/185f8cc836df52ac7c5daf825e183b44/href</a></iframe><p>With AssertJ it’s much easier. See it for yourself!</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/df6cba0aba6d526860dd62d7cb02dc9a/href">https://medium.com/media/df6cba0aba6d526860dd62d7cb02dc9a/href</a></iframe><p>For more info about testing Collections with AssertJ, go <a href="https://medium.com/enfuse-io/testing-java-collections-with-assertj-2fa678d80952">here</a>.</p><h3>Testing Exceptions</h3><p>In JUnit the Expected Exception rule allows us to expect an exception in the test case. Also, JUnit 4 lets you expect an exception through the <em>@Test </em>annotation’s <em>expected </em>attribute.</p><pre>@Test(expected = IOException.class)</pre><p>Let’s see how it works in this code example:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/29e7070b9670d85ba06c47b9ef997751/href">https://medium.com/media/29e7070b9670d85ba06c47b9ef997751/href</a></iframe><p>And in AssertJ we can do the same with only two lines of code. Isn’t that great!</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/520dda7cf47873db57f0f29faed95124/href">https://medium.com/media/520dda7cf47873db57f0f29faed95124/href</a></iframe><h3>Conclusion</h3><p>AssertJ is a library for writing better assertions. Using AssertJ you can write cleaner and more readable code. Plus it is super easy to learn and use. AssertJ works with any Java version over Java 6, it also supports assertions using the newer features in Java such as lambdas. Find more about methods in AssertJ <a href="https://assertj.github.io/doc/">here</a>. Happy testing!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=483b7d6dc997" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>