<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>selenium &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://en.wordpress.com/tag/selenium/</link>
	<description>Feed of posts on WordPress.com tagged "selenium"</description>
	<pubDate>Tue, 21 May 2013 21:28:17 +0000</pubDate>

	<generator>http://en.wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Selenium levels in tissue and prostate cancer risk]]></title>
<link>http://prostatecancerinfolink.net/2013/04/10/selenium-levels-in-tissue-and-prostate-cancer-risk/</link>
<pubDate>Wed, 10 Apr 2013 14:11:38 +0000</pubDate>
<dc:creator>Sitemaster</dc:creator>
<guid>http://prostatecancerinfolink.net/2013/04/10/selenium-levels-in-tissue-and-prostate-cancer-risk/</guid>
<description><![CDATA[According to a paper presented yesterday by Geybels et al. at the ongoing annual meeting of the Amer]]></description>
<content:encoded><![CDATA[According to a paper presented yesterday by Geybels et al. at the ongoing annual meeting of the Amer]]></content:encoded>
</item>
<item>
<title><![CDATA[Selenium: How to set Firefox profile.setPreference]]></title>
<link>http://shiyamtj.com/2013/04/10/selenium-how-to-set-firefox-profile-setpreference/</link>
<pubDate>Tue, 09 Apr 2013 20:06:33 +0000</pubDate>
<dc:creator>shiyamtj</dc:creator>
<guid>http://shiyamtj.com/2013/04/10/selenium-how-to-set-firefox-profile-setpreference/</guid>
<description><![CDATA[FirefoxProfile profile = new FirefoxProfile(); profile.setPreference(&#8220;network.proxy.type]]></description>
<content:encoded><![CDATA[FirefoxProfile profile = new FirefoxProfile(); profile.setPreference(&#8220;network.proxy.type]]></content:encoded>
</item>
<item>
<title><![CDATA[Proper Detox is the Key to a Healthy Horse]]></title>
<link>http://uckeleequine.wordpress.com/2013/04/09/proper-detox-is-the-key-to-a-healthy-horse/</link>
<pubDate>Tue, 09 Apr 2013 17:36:00 +0000</pubDate>
<dc:creator>uckeleequine</dc:creator>
<guid>http://uckeleequine.wordpress.com/2013/04/09/proper-detox-is-the-key-to-a-healthy-horse/</guid>
<description><![CDATA[Healthy detoxification is largely dependent on a healthy, balanced relationship between the exposure]]></description>
<content:encoded><![CDATA[<p>Healthy detoxification is largely dependent on a healthy, balanced relationship between the exposure to external toxins, the production of internal toxins from normal metabolism and the ability of the body, in particular the liver and the kidneys, to process and remove them.</p>
<p>Healthy toxic processing is apparent in the shine of the horse&#8217;s coat, clear, bright eyes and alert, energetic behavior.  Proper detox can also improve overall performance.</p>
<div id="attachment_523" class="wp-caption aligncenter" style="width: 522px"><a href="http://uckeleequine.wordpress.com/2013/04/09/proper-detox-is-the-key-to-a-healthy-horse/canstockphoto9878688/" rel="attachment wp-att-523"><img class=" wp-image-523 " alt="" src="http://uckeleequine.files.wordpress.com/2013/04/canstockphoto9878688.jpg?w=512&#038;h=446" width="512" height="446" /></a><p class="wp-caption-text">Healthy Detoxification makes for Healthy Horses</p></div>
<p>Major contributing factors to toxicity are preservatives, pesticide and herbicide residues, insecticides, toxic metals, cleaning solutions and fertilizer run-off from farm fields. Many toxic metals are commonly present in air and water. Multiple stresses, along with high-sugar, high-starch, highly processed feeds can also contribute to sluggish elimination and detoxification processes.</p>
<p>Specific, key ingredients can support healthy toxic processing and elimination to provide support for the detoxification systems.</p>
<p><strong>DL-Methionine, </strong>the sulphur containing amino acid, is an effective detoxifier of arsenic.</p>
<p><strong>MSM</strong> supports healthy detoxification processes, kidney and liver function and oxidative reactions.  It is also effective at improving arsenic elimination.</p>
<p><strong>Beta Alanine </strong>supports healthy muscular function, detoxification and metabolism.</p>
<p><strong>Magnesium</strong> supports cellular energy production, healthy glucose metabolism and acts as a buffer for the acids from toxic exposure and elimination.</p>
<p><strong>Trimethylglycine (TMG) and Dimethylglycine (DMG)</strong> work synergistically to support the basic detoxification mechanisms by contributing the amino acid glycine, as well as supplying valuable methyl groups, which are essential for the inactivation and elimination of toxic substances.</p>
<p><strong>Acetyl L-Carnitine </strong>is essential in the healthy processing of fatty acids as a source of energy, contributes to healthy endocrine balance and aids in the detoxification of the most common environmental pollutants.</p>
<p><strong>Niacin (B3), Calcium Pantothenate (B5), Thiamine (B1), Pyridoxine (B6), Riboflavin (B2) and Vitamin B12</strong> support healthy liver function, energy production, metabolic balance, stress recovery and detoxification.</p>
<p><strong>Mixed Tocopherols including Vitamin E </strong>support healthy cellular function, help reduce excessive oxidative stress and protect against free radical damage.</p>
<p><strong>Zinc and Copper </strong>have synergistic roles in helping combat environmental toxic effects, reducing excessive oxidation and supporting tissue integrity.</p>
<p><strong>Chromium</strong> supports normal, healthy glucose metabolism and energy production.</p>
<p><strong>Selenium</strong> directly supports healthy detoxification mechanisms, supports liver function, helps fight the effect of environmental toxins and exhibits a cellular protective benefit.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Cohort Study Indicates That Selenium May Be Protective Against Advanced Prostate Cancer]]></title>
<link>http://aacrnews.wordpress.com/2013/04/09/cohort-study-indicates-that-selenium-may-be-protective-against-advanced-prostate-cancer/</link>
<pubDate>Tue, 09 Apr 2013 17:00:01 +0000</pubDate>
<dc:creator>AACR Communications Staff</dc:creator>
<guid>http://aacrnews.wordpress.com/2013/04/09/cohort-study-indicates-that-selenium-may-be-protective-against-advanced-prostate-cancer/</guid>
<description><![CDATA[Higher toenail selenium levels were associated with a reduced risk for advanced prostate cancer. Toe]]></description>
<content:encoded><![CDATA[<table style="width:100%;" border="0">
<tbody>
<tr>
<td align="left" valign="top"><a class="addthis_button_google_plusone"></a><a href="http://www.addthis.com/bookmark.php?v=250&#38;pub=aacrnews" class="addthis_button"><img style="border:0;" src="http://s7.addthis.com/static/btn/v2/lg-share-en.gif" border="0" alt="Bookmark and Share" width="125" height="16" /></a>
</td>
</tr>
</tbody>
</table>
<p></br>
<ul>
<li>Higher toenail selenium levels were associated with a reduced risk for advanced prostate cancer.</li>
<li>Toenail selenium levels reflect long-term selenium intake.</li>
<li>Further studies in low-selenium populations are required.</li>
</ul>
<p>WASHINGTON, D.C. &#8212; A greater level of toenail selenium was associated with a significant decrease in the risk for advanced prostate cancer, according to data presented at the AACR Annual Meeting 2013, held in Washington, D.C., April 6-10. </p>
<p>&#8220;This could mean, based on our data and based on data from other studies, that selenium is a modifiable risk factor of advanced, clinically relevant prostate cancer,&#8221; said Milan S. Geybels, M.Sc., a doctoral candidate in cancer epidemiology at Maastricht University, in Maastricht, the Netherlands. </p>
<p>The Netherlands Cohort Study on diet and cancer is a prospective cohort study that includes 58,279 men who were aged 55 to 69 years at entry in September 1986. Geybels and colleagues analyzed data from 898 men who were diagnosed with advanced prostate cancer during 17.3 years of follow-up of the cohort.</p>
<p>According to Geybels, previous studies investigating the association between selenium levels and prostate cancer have yielded varying results. One large clinical trial showed that selenium supplementation had no protective effect, while several prospective, observational studies indicated that higher levels of selenium were associated with a reduced prostate cancer risk, especially for advanced prostate cancer. </p>
<p>&#8220;Our study is interesting because we specifically investigated men with advanced prostate cancer, a type of prostate cancer associated with a poorer prognosis,&#8221; Geybels said. &#8220;Also, while most of the prior research, including the large clinical trial, involved men with moderate-to-high selenium levels, men in The Netherlands Cohort Study have selenium levels that range from low to moderate. This is important because low selenium is expected to be related to a higher disease risk.&#8221; </p>
<p>He and his colleagues chose toenail selenium as the study biomarker because it reflects long-term exposure, as opposed to blood, which is best for monitoring recent selenium exposures. </p>
<p>The data revealed that greater levels of toenail selenium were associated with a substantially reduced risk for advanced prostate cancer. Men with the highest toenail selenium levels had a more than 60 percent lower risk for advanced prostate cancer compared with men with the lowest toenail selenium levels. </p>
<p>&#8220;Our findings need to be replicated in further prospective studies, with an extended follow-up for the assessment of incident advanced prostate cancer, and with a wide range of toenail selenium that includes low selenium levels,&#8221; Geybels said. &#8220;If our results can be confirmed, a prevention trial of selenium and prostate cancer in a low-selenium population may be justified.&#8221; </p>
<div style="text-align:center;"># # #</div>
<p><a href="http://www.aacr.org/PressRegistration">Press registration</a> for the AACR Annual Meeting 2013 is free to qualified journalists and public information officers.</p>
<p>Follow the AACR on Twitter: <a href="http://twitter.com/AACR" target="_blank">@aacr</a> <a href="http://twitter.com/#!/search/%23AACR" target="_blank">#aacr </a><br />Follow the AACR on Facebook: <a href="http://www.facebook.com/aacr.org" target="_blank">http://www.facebook.com/aacr.org</a></p>
<p><span style="text-decoration:underline;"><strong>About the American Association for Cancer Research</strong></span><br />Founded in 1907, the American Association for Cancer Research (AACR) is the world&#8217;s first and largest professional organization dedicated to advancing cancer research and its mission to prevent and cure cancer. AACR membership includes more than 34,000 laboratory, translational and clinical researchers; population scientists; other health care professionals; and cancer advocates residing in more than 90 countries. The AACR marshals the full spectrum of expertise of the cancer community to accelerate progress in the prevention, biology, diagnosis and treatment of cancer by annually convening more than 20 conferences and educational workshops, the largest of which is the AACR Annual Meeting with more than 17,000 attendees. In addition, the AACR publishes eight peer-reviewed scientific journals and a magazine for cancer survivors, patients and their caregivers. The AACR funds meritorious research directly as well as in cooperation with numerous cancer organizations. As the scientific partner of Stand Up To Cancer, the AACR provides expert peer review, grants administration and scientific oversight of team science and individual grants in cancer research that have the potential for near-term patient benefit. The AACR actively communicates with legislators and policymakers about the value of cancer research and related biomedical science in saving lives from cancer. For more information about the AACR, visit <a href="http://www.aacr.org" target="_blank">www.AACR.org</a>. </p>
<p><strong>Media Contact:</strong><br />Jeremy Moore<br />(215) 446-7109<br /><a href="mailto:Jeremy.Moore@aacr.org">Jeremy.Moore@aacr.org </a><br /><strong>In Washington, D.C., <br />April 6-10, 2013:</strong><br />(202) 249-4005</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Vitamins &amp; Minerals ]]></title>
<link>http://healthykidneys.wordpress.com/2013/04/09/vitamins-minerals/</link>
<pubDate>Tue, 09 Apr 2013 13:34:11 +0000</pubDate>
<dc:creator>julzcol</dc:creator>
<guid>http://healthykidneys.wordpress.com/2013/04/09/vitamins-minerals/</guid>
<description><![CDATA[I am someone who really dislikes taking any sort of pill but as I have had to change my diet, I am m]]></description>
<content:encoded><![CDATA[<p>I am someone who really dislikes taking any sort of pill but as I have had to change my diet, I am missing a few vital vitamins and minerals that the body needs from the foods we eat. As I am no longer getting these nutrients from food, I need to replace them with vitamins and mineral supplements. So I thought I would share with you what I take each day and the benefits of each.</p>
<p><a href="http://healthykidneys.files.wordpress.com/2013/04/vitamins.jpg"><img class="aligncenter size-medium wp-image-196" alt="" src="http://healthykidneys.files.wordpress.com/2013/04/vitamins.jpg?w=300&#038;h=300" width="300" height="300" /></a></p>
<p style="text-align:left;"><strong>Vitamin C </strong>helps reduce inflammation, provides anti-oxidant support, helps with bacterial infections, helps protect from damage caused by loss of blood supply, and helps reduce coagulation of the blood within the kidney.</p>
<p><strong>Co-Enzyme Q10 </strong>is a natural antioxidant and has the ability to enhance energy and immune system function. It is essential for the function of the mitochondria, which converts energy into usable forms and is involved in cell division and growth.</p>
<div><strong>Flaxseed Oil </strong>contains omega-3 essential fatty acids which reduces inflammation, high blood pressure, proteinuria and decreases cholesterol.</div>
<div></div>
<div></div>
<div><strong>Alpha Lipoic acid</strong> is the key kidney-healing nutrient. It helps increase cellular kidney energy for healing. In clinical studies, lipoic acid showed the ability to prevent Angiotension-II-induced glomerular and vascular damage in the kidneys and completely prevented the development of albuminuria. Lipoic acid also reduces blood glucose levels, prevents and reverses diabetic neuropathy, increases energy, assists detoxification from heavy metals and can be used in the treatment of cardiovascular disease and much more.</div>
<div></div>
<div></div>
<div><strong>Iron</strong> provides necessary iron supplementation, as most kidney disease patients suffer from anemia.</div>
<div></div>
<div></div>
<div><strong>Taurine</strong> helps reduce inflammation, shields again the development of diabetic nephropathy (inflammation of the kidney nephrons), helps heart function and lowers blood pressure.</div>
<div></div>
<div></div>
<div><strong>Vitamin D</strong> is essential for those with kidney disease because the body can simply no longer produce Vitamin D itself. The kidneys help produce the body’s Vitamin D stores. Vitamin D is also beneficial to the immune system.</div>
<div></div>
<div></div>
<div><strong>Multi-Vitamin (containing Zinc and Selenium)</strong></div>
<div><strong>Zinc</strong> enhances the immune system and assists with tissue repair.</div>
<div><strong>Selenium</strong> helps reduce inflammation and provides anti-oxidant support.</div>
<div></div>
<div></div>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Introduction to Selenium]]></title>
<link>http://deleodusanya.wordpress.com/2013/04/09/introduction-to-selenium/</link>
<pubDate>Tue, 09 Apr 2013 12:51:31 +0000</pubDate>
<dc:creator>Dele Odusanya</dc:creator>
<guid>http://deleodusanya.wordpress.com/2013/04/09/introduction-to-selenium/</guid>
<description><![CDATA[Selenium is a tool used to automate websites and web applications. What you do with that power is en]]></description>
<content:encoded><![CDATA[<p>Selenium is a tool used to automate websites and web applications. What you do with that power is entirely up to you. Primarily it is for automating web applications for testing purposes, but is certainly not limited to just that. Boring web-based administration tasks can (and should!) also be automated as well.</p>
<p>Selenium has the support of some of the largest browser vendors who have taken (or are taking) steps to make Selenium a native part of their browser. It is also the core technology in countless other browser automation tools, APIs and frameworks.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[How to do database testing using selenium rc]]></title>
<link>http://dennosecqtinstien.wordpress.com/2013/04/09/how-to-do-database-testing-using-selenium-rc/</link>
<pubDate>Tue, 09 Apr 2013 07:41:02 +0000</pubDate>
<dc:creator>Denno Secqtinstien</dc:creator>
<guid>http://dennosecqtinstien.wordpress.com/2013/04/09/how-to-do-database-testing-using-selenium-rc/</guid>
<description><![CDATA[How to do database testing using selenium rc? There are no selenium specific commands to do the data]]></description>
<content:encoded><![CDATA[<h2>How to do database testing using selenium rc?</h2>
<p>There are no selenium specific commands to do the database testing. But, you have the work around with native language. Here is the example how you can make database testing in selenium. The below mentioned commands will help you to begin with.</p>
<p>Before you use the below code <b>You should have created the DSN name for MS SQL Server DB or Oracle DB using ODBC drivers.</b> Here the name that we have used for the database DSN name is QT_Flight32. And the table in that database we are using is Orders. Hope the remaining steps you can easily understand.</p>
<p><b>//KEEP THE NAME OF THE PACKAGE</b><br />
package com.src.test;</p>
<p><b>//IMPORT THE SQL PACKAGE</b><br />
import java.sql.* ;</p>
<p><b>//DECLARE THE CLASS</b><br />
class JDBCODBCTestCase<br />
{</p>
<p><b>//WRITE THE MAIN METHOD TO CONNECT TO THE DATABASE </b><br />
public static void main( String args[] )<br />
{</p>
<p>try{</p>
<p><b>// LOAD THE DATABASE DRIVER</b><br />
Class.forName( &#8220;sun.jdbc.odbc.JdbcOdbcDriver&#8221; ) ;</p>
<p><b>// ESTABLISH THE CONNECTION TO THE DATABASE</b><br />
Connection conn = DriverManager.getConnection( &#8220;jdbc:odbc:QT_Flight32&#8243; ) ;</p>
<p><b>// GET A STATEMENT FOR THE CONNECTION</b><br />
Statement stmt = conn.createStatement() ;</p>
<p><b>// PREPARE THE SQL STATEMENT</b><br />
String strSQL = &#8220;SELECT * FROM Orders&#8221;;</p>
<p><b>// EXECUTE THE SQL QUERY AND STORE IN RESULTS SET</b><br />
ResultSet rs = stmt.executeQuery( strSQL ) ;</p>
<p><b>// LOOP THE RESULT TILL IT REACHED END</b><br />
<b>// rs.getString(1) &#8211; FIRST COLUMN</b><br />
<b>// rs.getString(2) &#8211; SECOND COLUMN ETC</b><br />
while( rs.next() )<br />
System.out.println( rs.getString(1) + rs.getString(2)+ rs.getString(3)+ rs.getString(4)) ;</p>
<p><b>// CLOSE THE RESULT, STATEMENT AND CONNECTION</b><br />
rs.close() ;<br />
stmt.close() ;<br />
conn.close() ;</p>
<p>}<br />
<b>// HANDLE THE SQL EXCEPTION</b><br />
catch( SQLException se ) {</p>
<p>System.out.println( &#8220;SQL Exception:&#8221; ) ;</p>
<p><b>// PRINT TILL ALL THE ECEPTIONS ARE RAISED</b><br />
while( se != null ) {</p>
<p>System.out.println( &#8220;State : &#8221; + se.getSQLState() ) ;<br />
System.out.println( &#8220;Message: &#8221; + se.getMessage() ) ;<br />
System.out.println( &#8220;Error : &#8221; + se.getErrorCode() ) ;</p>
<p>se = se.getNextException() ;</p>
<p>}</p>
<p>}<br />
<b>//CATCH THE CLASS EXCEPTION</b><br />
catch( Exception e ) {</p>
<p>System.out.println( e ) ;</p>
<p>}<br />
}</p>
<p>}</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[HealthyMuslim.Com | Selenium: A Powerful Anti-Cancer Mineral Essential for Healthy Cells]]></title>
<link>http://ummahaatulmumineen.wordpress.com/2013/04/09/healthymuslim-com-selenium-a-powerful-anti-cancer-mineral-essential-for-healthy-cells/</link>
<pubDate>Mon, 08 Apr 2013 23:48:12 +0000</pubDate>
<dc:creator>Umm Isaa bint Mace Abdullah As-Salafiyyah</dc:creator>
<guid>http://ummahaatulmumineen.wordpress.com/2013/04/09/healthymuslim-com-selenium-a-powerful-anti-cancer-mineral-essential-for-healthy-cells/</guid>
<description><![CDATA[Selenium: A Powerful Anti-Cancer Mineral Essential for Healthy Cells.]]></description>
<content:encoded><![CDATA[<p><a href="http://www.healthymuslim.com/articles/ievso-selenium-a-powerful-anti-cancer-mineral-essential-for-healthy-cells.cfm">Selenium: A Powerful Anti-Cancer Mineral Essential for Healthy Cells</a>.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Running Selenium tests from Visual Studio &ndash; Step by step]]></title>
<link>http://amirshenouda.wordpress.com/2013/04/08/running-selenium-tests-from-visual-studio-step-by-step/</link>
<pubDate>Mon, 08 Apr 2013 06:54:53 +0000</pubDate>
<dc:creator>amirsamy</dc:creator>
<guid>http://amirshenouda.wordpress.com/2013/04/08/running-selenium-tests-from-visual-studio-step-by-step/</guid>
<description><![CDATA[From Firefox, record new selenium test, for example for Google search Export the test to C# web driv]]></description>
<content:encoded><![CDATA[<p>From Firefox, record new selenium test, for example for Google search</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-14-39.png"><img title="2013-04-07_13-14-39" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-14-39" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-14-39_thumb.png?w=244&#038;h=212" width="244" height="212" /></a></p>
<p>Export the test to C# web drive</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-15-06.png"><img title="2013-04-07_13-15-06" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-15-06" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-15-06_thumb.png?w=235&#038;h=244" width="235" height="244" /></a></p>
<p>This is how it looks like after export</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-15-50.png"><img title="2013-04-07_13-15-50" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-15-50" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-15-50_thumb.png?w=244&#038;h=146" width="244" height="146" /></a></p>
<p>Open visual studio, create new test project</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-16-36.png"><img title="2013-04-07_13-16-36" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-16-36" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-16-36_thumb.png?w=244&#038;h=158" width="244" height="158" /></a></p>
<p>By default the file UnitTest1.cs is created</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-25-47.png"><img title="2013-04-07_13-25-47" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-25-47" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-25-47_thumb.png?w=244&#038;h=91" width="244" height="91" /></a></p>
<p>Create a new cs file, name it for example GoogleSearch</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-25-54.png"><img title="2013-04-07_13-25-54" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-25-54" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-25-54_thumb.png?w=244&#038;h=115" width="244" height="115" /></a></p>
<p>Copy the code from the cs file generated by selenium and paste it in the file GoogleSearch.cs</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-26-42.png"><img title="2013-04-07_13-26-42" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-26-42" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-26-42_thumb.png?w=244&#038;h=150" width="244" height="150" /></a></p>
<p>Add reference in the project to Selenium .Net WebDriver, WebDriver.dll and WebDriver.Support.dl</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-32.png"><img title="2013-04-07_13-29-32" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;margin:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-29-32" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-32_thumb.png?w=244&#038;h=169" width="244" height="169" /></a><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-07.png"><img title="2013-04-07_13-29-07" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-29-07" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-07_thumb.png?w=244&#038;h=145" width="244" height="145" /></a></p>
<p>Now the references added, you can see that the editor recognizes the selenium name spaces</p>
<p>using OpenQA.Selenium;   <br />using OpenQA.Selenium.Firefox;    <br />using OpenQA.Selenium.Support.UI;</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-40.png"><img title="2013-04-07_13-29-40" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-07_13-29-40" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-07_13-29-40_thumb.png?w=244&#038;h=105" width="244" height="105" /></a></p>
<p>Find and replace “TestFixture” to “TestClass”, “SetUp” to “TestInitialize()”, “Test” to “TestMethod”, “TearDown” to “TestCleanup()”</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_00-31-32.png"><img title="2013-04-08_00-31-32" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-08_00-31-32" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_00-31-32_thumb.png?w=244&#038;h=228" width="244" height="228" /></a></p>
<p>To run with Chrome, download chromedriver.exe from <a href="https://code.google.com/p/chromedriver/downloads/list">https://code.google.com/p/chromedriver/downloads/list</a>, place it in the bin folder</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-45-49.png"><img title="2013-04-08_09-45-49" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-08_09-45-49" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-45-49_thumb.png?w=206&#038;h=244" width="206" height="244" /></a></p>
<p>Change the driver in the code to Chrome then run the test</p>
<p>driver = new OpenQA.Selenium.Chrome.ChromeDriver();</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-45-09.png"><img title="2013-04-08_09-45-09" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-08_09-45-09" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-45-09_thumb.png?w=244&#038;h=99" width="244" height="99" /></a></p>
<p>Running the test, chrome will open, and Google search page will be displayed, displaying search results then closed</p>
<p><a href="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-51-36.png"><img title="2013-04-08_09-51-36" style="border-top:0;border-right:0;background-image:none;border-bottom:0;padding-top:0;padding-left:0;border-left:0;display:inline;padding-right:0;" border="0" alt="2013-04-08_09-51-36" src="http://amirshenouda.files.wordpress.com/2013/04/2013-04-08_09-51-36_thumb.png?w=244&#038;h=187" width="244" height="187" /></a></p>
<p>This was a step by step example on running selenium test from visual studio</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Selenium]]></title>
<link>http://selenium238.wordpress.com/2013/04/07/selenium/</link>
<pubDate>Sun, 07 Apr 2013 19:03:30 +0000</pubDate>
<dc:creator>selenium238</dc:creator>
<guid>http://selenium238.wordpress.com/2013/04/07/selenium/</guid>
<description><![CDATA[Brooding.]]></description>
<content:encoded><![CDATA[<p><img src="http://selenium238.files.wordpress.com/2013/04/anfgcvhgfxgf.jpeg" class="size-full" alt="Selenium" /></p>
<p>Brooding.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Selenium -trustAllSSLCertificates Parameter and Custom Firefox Profile]]></title>
<link>http://automatictester.wordpress.com/2013/04/07/selenium-trustallsslcertificates-parameter-and-custom-firefox-profile/</link>
<pubDate>Sun, 07 Apr 2013 13:53:19 +0000</pubDate>
<dc:creator>automatictester</dc:creator>
<guid>http://automatictester.wordpress.com/2013/04/07/selenium-trustallsslcertificates-parameter-and-custom-firefox-profile/</guid>
<description><![CDATA[In previous post I described how to start Firefox with custom profile using Selenium. In my case usi]]></description>
<content:encoded><![CDATA[In previous post I described how to start Firefox with custom profile using Selenium. In my case usi]]></content:encoded>
</item>
<item>
<title><![CDATA[Selenium - Running Custom Firefox Profile]]></title>
<link>http://automatictester.wordpress.com/2013/04/07/selenium-running-custom-firefox-profile/</link>
<pubDate>Sun, 07 Apr 2013 13:45:54 +0000</pubDate>
<dc:creator>automatictester</dc:creator>
<guid>http://automatictester.wordpress.com/2013/04/07/selenium-running-custom-firefox-profile/</guid>
<description><![CDATA[Today I&#8217;m going to cover running custom firefox profile with various flavours of Selenium. Cus]]></description>
<content:encoded><![CDATA[Today I&#8217;m going to cover running custom firefox profile with various flavours of Selenium. Cus]]></content:encoded>
</item>
<item>
<title><![CDATA[Automating the Web with Selenium: Complete Tasks Automatically and Write Test Cases!]]></title>
<link>http://irwinkwan.com/2013/04/05/automating-the-web-with-selenium-complete-tasks-automatically-and-write-test-cases/</link>
<pubDate>Fri, 05 Apr 2013 21:54:20 +0000</pubDate>
<dc:creator>irwinhkwan</dc:creator>
<guid>http://irwinkwan.com/2013/04/05/automating-the-web-with-selenium-complete-tasks-automatically-and-write-test-cases/</guid>
<description><![CDATA[While teaching Software Engineering I during the Winter 2013 term, I learned of a web testing suite]]></description>
<content:encoded><![CDATA[<p>While teaching Software Engineering I during the Winter 2013 term, I learned of a web testing suite named <a href="http://docs.seleniumhq.org">Selenium</a>.</p>
<p>I was on the lookout for a good unit testing suite for Javascript. I had previously been introduced to the <a href="http://yuilibrary.com/projects/yuitest/">YUI Testing Framework</a>, which provides a console and enables you to easily write and run tests from a browser window, but one limitation of YUI is that, out of the box, it doesn&#8217;t support interaction with the site itself. So, while the basic usage is good for verifying libraries and similar, I wanted something that was able to interact with page elements in a different way.</p>
<p>Enter Selenium. Now, here&#8217;s a way to not only automate web interactions, but to make them into automated unit tests for my research projects. This post is going to serve as a brief introduction to Selenium and how to start using it to interact with websites.</p>
<h1>Selenium</h1>
<p>Selenium is a web automation framework that enables a user to essentially script a web site. In this post we&#8217;ll talk about using Selenium version 2, which is the main, up-to-date version of the software.</p>
<p>There are two main ways for you to interact with a website.</p>
<h2>The Selenium IDE: Recording actions by Demonstration</h2>
<p>First, you can use the Selenium IDE, which is a Firefox plugin that allows you to demonstrate interactions with a web site. You essentially record actions and then as you click around the page, type in form elements, and push buttons, the IDE records the actions for you in a pseudo-markup language. (If you happen to follow my other research, it is actually somewhat similar to CoScripter, another program-by-demonstration tool for the web, but with better web interaction and fewer features. For example, Selenium cannot store temporary data into tables.)</p>
<p>Thus, even with minimal web development or programming experience, you could create a script for Selenium that plays back, for example, a series of clicks on a page, completes a survey, or similar.</p>
<p>There are some limitations with the IDE. The main one that led me to using the WebDriver (below) is that it doesn&#8217;t interact very well with &#8220;contentEditable&#8221; div tags and other HTML5 elements.</p>
<p>Note that the Selenium IDE is version 1.x, which does NOT correspond to Selenium itself (which is version 2.x).</p>
<h2>The Selenium WebDriver: Programming actions in code</h2>
<p>The second way to interact with a website is using the Selenium Webdriver, which is a driver that essentially launches a website and then enables you to look through that website&#8217;s DOM to interact with elements on the page. Thus, you can use your own browser, like Firefox or Internet Explorer to load and navigate a web site.</p>
<p>I wanted Selenium to be able to work with a highly interactive web app: Gidget. <a href="http://gidget.ischool.uw.edu">Gidget</a> is a programming game for kids and teenagers that I am working on in collaboration with <a href="http://faculty.washington.edu/ajko/">Andy Ko</a> and <a href="http://students.washington.edu/mjslee/">Michael Lee</a>. Gidget runs with a lot of HTML5, JQuery, and Javascript and is extremely visual &#8211; something that seems perfect for Selenium.</p>
<p>Unfortunately, since Gidget isn&#8217;t available publicly yet, I can&#8217;t actually put tests on the blog that&#8217;ll directly run Gidget so instead I&#8217;ll use Google.</p>
<h2>Building a Selenium Script</h2>
<p>Selenium has a number of bindings in Java, Ruby, Python, and Javascript. I personally chose to use Python &#8211; I like its concise syntax and the fact that it has pretty good library support. I&#8217;ll focus exclusively on Python in this particular post. Most of the Java bindings can be derived from the Python commands if you remove the underscores and instead use CamelCase &#8211; for example, &#8220;element.is_enabled()&#8221; in Python would be &#8220;element.isEnabled()&#8221; in Java.</p>
<p>To install Selenium, you generally need to only type
<pre>pip install selenium</pre>
<p> assuming that Python exists already on your system.</p>
<p>The first place I&#8217;m going to point you at is the <a href="http://docs.seleniumhq.org/docs/03_webdriver.jsp#introducing-the-selenium-webdriver-api-by-example">Selenium Documentation Example of WebDriver</a>, where they already include an example of making a query on Google. Here&#8217;s a reproduction of the code.</p>
<pre>from selenium import webdriver
from selenium.common.exceptions import TimeoutException
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC

# Create a new instance of the Firefox driver
driver = webdriver.Firefox()

# go to the google home page
driver.get("http://www.google.com")

# find the element that's name attribute is q (the google search box)
inputElement = driver.find_element_by_name("q")

# type in the search
inputElement.send_keys("Cheese!")

# submit the form (although google automatically searches now without submitting)
inputElement.submit()

# the page is ajaxy so the title is originally this:
print driver.title

try:
    # we have to wait for the page to refresh, the last thing that seems to be updated is the title
    WebDriverWait(driver, 10).until(EC.title_contains("cheese!"))

    # You should see "cheese! - Google Search"
    print driver.title

finally:
    driver.quit()</pre>
<p>It works exactly as advertised and opens up a web browser, goes to Google, and then searches for &#8220;cheese!&#8221;. However, there are a number of features that are essential to actually testing web pages.</p>
<h3>Waiting for Pages</h3>
<p>The unfortunate reality of web pages nowadays is that you have to wait a lot. Whether it&#8217;s a form submit where you have to wait for the POST request to complete, or some really slow JQuery fading box, not everything you want to interact with is available. To get around this, you have to use the &#8220;wait&#8221; commands in Selenium.</p>
<p>The Selenium documents do provide a few examples but I had to do a lot of searching and testing to get things working so I&#8217;ll just provide my use cases here directly.</p>
<p>To wait for an element to appear in Selenium, you need to provide an explicit wait along with a condition. It basically waits until either the identified element loads, or until the timeout passes (at which point it will throw an exception). There is an example of that in the Selenium example above, but if you have Google Instant turned on, you&#8217;ll realise notice that Google now returns search results to you as soon as you start typing. How can you interact with page elements if you don&#8217;t even know what&#8217;s going to pop up, when?</p>
<p>In this case, we&#8217;re going to wait until the &#8220;Search Results&#8221; text pops up.</p>
<pre>from selenium import webdriver
from selenium.common.exceptions import TimeoutException
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support.ui import Select
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
from selenium.common.exceptions import NoSuchElementException

if __name__ == "__main__":
    driver = webdriver.Firefox()
    wait = WebDriverWait(driver, 100)
    driver.get("http://google.com")
    
    inputElement = driver.find_element_by_name("q")
    inputElement.send_keys("Irwin Kwan")
    
    wait.until(EC.element_to_be_clickable((By.XPATH, "//a[@href='http://irwinhkwan.wordpress.com/']")))
    blog = driver.find_element_by_xpath("//a[@href='http://irwinhkwan.wordpress.com/']")
    blog.click()
    
    driver.quit()</pre>
<p>Basically, the driver loads, we set up a &#8220;wait&#8221; that waits up to 100ms, and then we do a search on Google for my name. Note that we don&#8217;t actually submit the form &#8211; instead, we wait for the link to my blog to appear in the Google search results, find the element, then click on it. And yes, this is a cheap way to rack up those hits for my blog, so everyone run this code. <img src='http://s1.wp.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>There are a lot of expected conditions available in Selenium and this is probably the most important thing to be aware of when first starting. You can&#8217;t interact with page elements unless they&#8217;re available, after all. Here are some of the useful ones:</p>
<ul>
<li>EC.element_to_be_clickable: Wait for the element to be clickable. Good for elements that aren&#8217;t always visible or enabled. I use this a lot in the game.
<li>EC.visibility_of_element_located: Wait for the element to be visible. A lot of pages load all of their content, but hide it from the user. Here&#8217;s how you ensure that what&#8217;s being interacted with is actually visible.
<li>EC.presence_of_element_located: The element exists somewhere on the page.
</ul>
<p>There are a lot of these expected conditions. A full list is available on the <a href="http://selenium.googlecode.com/git/docs/api/py/webdriver_support/selenium.webdriver.support.expected_conditions.html#module-selenium.webdriver.support.expected_conditions">selenium.webdriver.support.expected_conditions API document page.</a> </p>
<p>The second key aspect here is the interaction. To do this, you have to &#8220;find&#8221; the element. So far, I&#8217;ve used two main ways of finding an element: ID, and XPath.</p>
<h4>Finding elements by ID</h4>
<p>Finding an element by ID is pretty much what it sounds like: searching for an element using its ID tag. ID tags are unique in the DOM and are therefore ideal for searching and testing. You can use it like this:</p>
<pre>driver.find_element_by_id("menubutton_id")</pre>
<h4>Finding elements by XPath</h4>
<p>XPath is a query language designed to navigate XML. I won&#8217;t go through all of the details of XPath here, but I&#8217;ll present a few basic use cases. You basically can search on a number of conditions that you specify in the language so you can see if that element exists in the DOM.</p>
<ul>
<li>If you want to search if a specific tag exists:
<pre>driver.find_element_by_xpath("//h1")</pre>
<li>If you want to search for nested tags:
<pre>driver.find_element_by_xpath("/html/body/h1")</pre>
<li>If you want to search that text within the tags matches:
<pre>driver.find_element_by_xpath("//h1[text()='Heading 1']")</pre>
<li>If you want to search for text in attributes
<pre>driver.find_element_by_xpath("//img[@title='Irwin Kwan']")</pre>
</ul>
<p>With these two find_element commands, you can find most of what you need in your web pages. Selenium supports a number of other ways to search, including searching by CSS, but I haven&#8217;t needed to use it yet.</p>
<h3>Dynamic Interactions with a Page</h3>
<p>Another issue I encountered with the Gidget game is clicking through introduction text when I didn&#8217;t know how many pages were present. Essentially, the problem is that there&#8217;s a button that I have to push on the page, and if I push it a certain number of times, it&#8217;ll be disabled. However, I don&#8217;t know how many times I have to push it because it might be different each time.</p>
<p>I managed to get around this with a little fragment of code below:</p>
<pre>wait.until(EC.element_to_be_clickable((By.ID, 'main_buttonMissionTextNext')))
while EC.element_to_be_clickable((By.ID,'main_buttonMissionTextNext')):
    driver.find_element_by_id("main_buttonMissionTextNext").click()
    if not driver.find_element_by_id("main_buttonMissionTextNext").click().is_enabled():
        break
    wait.until(EC.element_to_be_clickable((By.ID, 'main_buttonMissionTextNext')))</pre>
<p>There were two gotchas here: First, I wasn&#8217;t aware of it at the time, but the button was actually regenerated whenever you clicked it, so I had to search for it again when I clicked it. Second, I didn&#8217;t realise that there was an is_enabled() function you could use to test if an element is enabled or not. But now, you know!</p>
<p>I posted a <a href="http://stackoverflow.com/questions/15824156/how-can-i-make-selenium-click-through-a-variable-number-of-next-buttons/15825173">StackOverflow question about this (which I ended up answering myself).</a></p>
<h3>Using the Selenium IDE and the Selenium WebDriver Together To Save Time</h3>
<p>While writing code is nice and fun, HTML pages are very large and are covered with tags with various IDs. It becomes tedious very quickly, even with good web development debugging tools, to search through the DOM elements to identify what you need to interact with, then writing the code to search and click on it.</p>
<p>So work smarter, not harder and use the Selenium IDE. If you record your actions with a page and save it in the Selenium IDE, you can use &#8220;Export Test Case As&#8230; &#62; Python 2 / unittest / WebDriver&#8221;. Now you have Python code for that series of actions that you just performed and can integrate it into your other tests.</p>
<p>In my case, I used the Selenium IDE to automatically complete an exit survey in Gidget, then exported it and used the code in my other test suites. It&#8217;s a great way to save time writing code.</p>
<h2>Making your code into a Test Suite</h2>
<p>In Python, the unit testing is built in. You simply have to import unittest, create a class that extends it, and then write your setup and teardown functions, along with a method beginning with &#8220;test&#8221;. Here&#8217;s the previous code for interacting with Google converted into a Python test suite.</p>
<pre>import unittest

from selenium import webdriver
from selenium.common.exceptions import TimeoutException
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support.ui import Select
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
from selenium.common.exceptions import NoSuchElementException

class WebTester(unittest.TestCase):
    def setUp(self):
        self.driver = webdriver.Firefox()
        self.wait = WebDriverWait(self.driver, 100)
        
    def test_load_blog(self):
        self.driver.get("http://google.com")
    
        inputElement = self.driver.find_element_by_name("q")
        inputElement.send_keys("Irwin Kwan")
    
        self.wait.until(EC.element_to_be_clickable((By.XPATH, "//a[@href='http://irwinhkwan.wordpress.com/']")))
        blog = self.driver.find_element_by_xpath("//a[@href='http://irwinhkwan.wordpress.com/']")
        blog.click()
        
        self.wait.until(EC.visibility_of_element_located((By.XPATH, "//h2[text()='Irwin Kwan']")))
        self.assertTrue(self.driver.find_element_by_xpath("//h2[text()='Irwin Kwan']"))
    
    def tearDown(self):
        self.driver.quit()
    
if __name__ == "__main__":
    unittest.main()

</pre>
<p>If you place multiple test suite classes in the file, unittest will run them all. Selenium will launch a new, fresh browser instance for each one as well.</p>
<h2>Conclusion: Web Automation is Pretty Cool</h2>
<p>I&#8217;m really just a new user. Selenium has a number of features that I haven&#8217;t needed and therefore don&#8217;t know much about. There&#8217;s a &#8220;remote control&#8221; mode that allows you to use a separate server to run tests for you. There are ways to store session variables, load specific Firefox profiles with add-ons, and there is a &#8220;Selenium server&#8221; mode as well. If you need these features, chances are you&#8217;ll be able to find information about them on <a href="http://docs.seleniumhq.org/docs/">the Selenium site documents</a>.</p>
<p>I feel that this information should set most people up with enough information to get started with Selenium and making it work for them in a useful way. I hope that this post is useful to you guys!</p>
<p>Happy automating!</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[BO-SE, MU-SE]]></title>
<link>http://askavetsheep.wordpress.com/2013/04/05/bo-se-mu-se/</link>
<pubDate>Fri, 05 Apr 2013 20:35:09 +0000</pubDate>
<dc:creator>Ask-a-Vet Sheep</dc:creator>
<guid>http://askavetsheep.wordpress.com/2013/04/05/bo-se-mu-se/</guid>
<description><![CDATA[Come on folks lets try to make some sense of what is going on here. I received correspondence from a]]></description>
<content:encoded><![CDATA[<p>Come on folks lets try to make some sense of what is going on here. I received correspondence from a producer that among other things was giving one tenth of a cc of MU-SE at birth. For starters the dosage is 1cc per 200# of body wt. for weanling calves. Not approved for sheep. We are overdosing on selenium immediately and each cc of the product contains 68 units of Vitamin E so we are giving 7 USP units of Vitamin E when the recommended dose is some where between 300 to 1000 units. Now I am not singling out this one instance I encounter these situations almost daily with these two products. Someone has done a good sales job.</p>
<p>BO-SE is similar, it is recommended 1 cc per 40# in lambs and that is the minimum weight it is to be given, read the label folks. It also has a whopping 68 units of E per cc. Its not recommended for pregnant ewes due to what is probably an occasional anaphylactic reaction.</p>
<p>Whats the most economical and safest answer? Feeding iodine, selenium and Vitamin E thru the salt. Big Gain Feeds have this product complete or if not in the area serviced by them we have products <a href="http://www.pipevet.com/pc_combined_results.asp?tab=product&#38;search_prod=%28searchlike~p.sku~6249&#124;Or&#124;searchlike~p.nm~6249&#124;Or&#124;searchlike~p.ds~6249&#124;Or&#124;searchlike~p.child_skus~6249&#124;Or&#124;searchlike~p.child_nms~6249&#124;Or&#124;searchlike~p.search_terms~6249%29&#38;search_keyword=6249" target="_blank">#6249</a> and <a href="http://www.pipevet.com/pc_combined_results.asp?tab=product&#38;search_prod=%28searchlike~p.sku~8770&#124;Or&#124;searchlike~p.nm~8770&#124;Or&#124;searchlike~p.ds~8770&#124;Or&#124;searchlike~p.child_skus~8770&#124;Or&#124;searchlike~p.child_nms~8770&#124;Or&#124;searchlike~p.search_terms~8770%29&#38;search_keyword=8770" target="_blank">#8770</a> that can be easily mixed with salt, #6249 contains E, #8770 doesn&#8217;t.<br />
You certainly don&#8217;t need Vitamin E when animals are on pasture or early in fall when feed stuffs still retain their Vitamin E. These products provide iodine as well and complete you entire mineral needs for breeding sheep.</p>
<p>Whats the take home? Selenium and Vitamin E should be provided in the ration as a safer and more cost effective route of administration.</p>
<p>DON&#8217;T OVERDOSE OR REPEAT INJECTIONS OF THESE TWO PRODUCTS OR ACUTE DEATH MAY RESULT.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Drop down Select - WebDriver]]></title>
<link>http://learnwebdriver.wordpress.com/2013/04/05/drop-down-select-webdriver/</link>
<pubDate>Fri, 05 Apr 2013 20:03:00 +0000</pubDate>
<dc:creator>jvsantoshsarma</dc:creator>
<guid>http://learnwebdriver.wordpress.com/2013/04/05/drop-down-select-webdriver/</guid>
<description><![CDATA[In web application we see many drop down lists for many input fields (Ex : gender, age, country..etc]]></description>
<content:encoded><![CDATA[<p>In web application we see many drop down lists for many input fields (Ex : gender, age, country..etc). This drop down option is different from normal text/numeric&#160;input field. It has separate tag in html.</p>
<p>In automation while filling most of the forms we need to fill/select the drop down values also. For achieving this WebDriver has separate class called <a href="http://selenium.googlecode.com/svn/trunk/docs/api/java/org/openqa/selenium/support/ui/Select.html" target="_blank">Select</a>.</p>
<p>In this post we will see what are all different method available in Select class.</p>
<div align="left">
<p>Consider below example</p>
<div style="background-color:#cee3f6;border-radius:25px;border:2px solid #a1a1a1;box-shadow:10px 10px 5px #888;padding:10px 40px;width:80%;"><code><code><br />
ChennaiHyderabadBangalore</code></code>&#160;<br />
<ins datetime="2013-04-11T11:03:37+00:00"></p>
<p><b>HTML CODE</b><br />
&#60;select id=&#8221;city&#8221;&#62;<br />
&#60;option value=&#8221;Op1&#8243;&#62;Chennai&#60;/option&#62;<br />
&#60;option value=&#8221;Op2&#8243;&#62;Hyderabad&#60;/option&#62;<br />
&#60;option value=&#8221;Op3&#8243;&#62;Bangalore&#60;/option&#62;<br />
&#60;/select&#62;</div>
<p><b><span style="background-color:#cfe2f3;text-decoration:underline;">Select an Option</span></b><br />
Available methods for selecting an option are</p>
<ol>
<li>selectByIndex(int index)</li>
<li>selectByValue(java.lang.String value)</li>
<li>selectByVisibleText(java.lang.String text)</li>
</ol>
<div><b>selectByIndex(int index)</b></div>
<div>Select the option at the given index.</div>
<p><b>Usage :</b></p>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:70%;">new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByIndex(2);</div>
<p>In above example it will select the <i>Hyderabad&#160;</i>because it is in index 2.</p>
<p><b>selectByValue(java.lang.String value)</b><br />
Select all options that have a value matching the argument.<br />
<b>Usage :</b></p>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:70%;">new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByValue(&#8220;Op3&#8243;);</div>
<p>In above example it will select the <i>Bangalore&#160;</i> based on the value attribute of that option.</p>
<p><b>selectByVisibleText(java.lang.String text)</b><br />
Select all options that display text matching the argument.<br />
<b>Usage :</b></p>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:80%;">new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByVisiableText(&#8220;Chennai&#8221;);</div>
<p>In above example it will select the <i>Chennai</i> based on the visible text.</p>
<p><b><span style="background-color:#cfe2f3;text-decoration:underline;">De-select an option</span></b><br />
Available methods for de-selecting an option(s) are,</p>
<ol>
<li>deselectAll()</li>
<li>deselectByIndex(int index)</li>
<li>deselectByValue(java.lang.String value)</li>
<li>deselectByVisibleText(java.lang.String text)</li>
</ol>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:80%;">
<div><b>deselectAll()</b></div>
<div>
<ul>
<li>Clear all selected entries.</li>
</ul>
</div>
<div><b>deselectByIndex(int index)</b></div>
<div>
<ul>
<li>Deselect the option at the given index.</li>
</ul>
</div>
<div><b>deselectByValue(java.lang.String value)</b></div>
<div>
<ul>
<li>Deselect all options that have a value matching the argument.</li>
</ul>
</div>
<div><b>deselectByVisibleText(java.lang.String text)</b></div>
<div>
<ul>
<li>Deselect all options that display text matching the argument.</li>
</ul>
</div>
</div>
<div><b>&#160;</b></div>
<p><b><span style="background-color:#cfe2f3;text-decoration:underline;">Getting all options</span></b><br />
Some times we may in need to get all the options available in drop down list in that case below method will be useful.</p>
<ul>
<li>getOptions();</li>
</ul>
<p><b>getOptions()</b><br />
It will return All options belonging to this select tag<br />
<b>Usage :</b></p>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:90%;">List allCities=new Select(driver.findElement(By.id(&#8220;city&#8221;))).getOptions();<br />
for(WebElement city:allCities)<br />
{<br />
System.out.println(city.getText()); &#160; &#160;//It will return the text of each option<br />
System.out.println(city.getAttribute(&#8220;value&#8221;)); &#160; &#160;//it will return the value attribute of each option<br />
}</div>
</div>
<p><b><span style="background-color:#cfe2f3;text-decoration:underline;">Get Selected Option(s)</span></b><br />
If you want to verify whether the proper value got selected in particular drop down list you can make use of below methods.</p>
<ol>
<li>getFirstSelectedOption();</li>
<li>getAllSelectedOptions() ;</li>
</ol>
<div><b>getFirstSelectedOption();</b></div>
<div>
<ul>
<li>The first selected option in this select tag (or the currently selected option in a normal select)</li>
</ul>
</div>
<p><b>getAllSelectedOptions() ;</b></p>
<ul>
<li>It will return List of&#160;All selected options belonging to this select tag. (This will be useful for multiselect picklist)</li>
</ul>
<p><b><span style="background-color:#cfe2f3;text-decoration:underline;">Handling multi-select pick list</span></b></p>
<div style="background-color:#cee3f6;border-radius:25px;border:2px solid #a1a1a1;box-shadow:10px 10px 5px #888;padding:10px 40px;width:80%;">
<p>Chennai Hyderabad Bangalore &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;<b>HTML CODE</b></p>
<p>Chennai<br />
Hyderabad<br />
Bangalore</p>
</div>
<p>Handling multi select pick list same as normal drop down( single pick list).<br />
For selecting both Hyderabad, Bangalore option you need to use one of the below&#160;logics.</p>
<div style="background-color:#f8e0e0;border-radius:25px;border:2px solid #a1a1a1;padding:10px 20px;width:80%;">new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByIndex(2);<br />
new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByIndex(3);<br />
<b>Or</b><br />
new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByvalue(&#8220;Op2&#8243;);<br />
new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByvalue(&#8220;Op3&#8243;);<br />
<b>Or</b><br />
new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByVisiableText(&#8220;Hyderabad&#8221;);<br />
new Select(driver.findElement(By.id(&#8220;city&#8221;))).selectByVisiableText(&#8220;Bangalore&#8221;);</div>
<p>I hope you understand WebDriver Select class usage in automation.</p>
<p>Happy Selecting <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Regards,<br />
SantoshSarma</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Two ways to assert text with WebDriver]]></title>
<link>http://alchemyse.wordpress.com/2013/04/05/two-ways-to-assert-text-with-webdriver/</link>
<pubDate>Fri, 05 Apr 2013 19:57:42 +0000</pubDate>
<dc:creator>XanthicSky</dc:creator>
<guid>http://alchemyse.wordpress.com/2013/04/05/two-ways-to-assert-text-with-webdriver/</guid>
<description><![CDATA[You can use this: driver.getPageSource().contains(pattern) or find the element with the text and ass]]></description>
<content:encoded><![CDATA[<p>
You can use this:</p>
<p><code>driver.getPageSource().contains(pattern)</code></p>
<p>or find the element with the text and assert that it is visible.</p>
<p><code> WebElement el = driver.findElement(By.xpath("//*[contains(.,'" + pattern + "')]")); </code></p>
<p>I find that the latter works better in most cases. I wrap it in a try/catch block to grab any NoSuchElementException.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Select element with jQuery where the id contains specific text.]]></title>
<link>http://alchemyse.wordpress.com/2013/04/05/select-element-with-jquery-where-the-id-contains-specific-text/</link>
<pubDate>Fri, 05 Apr 2013 15:42:54 +0000</pubDate>
<dc:creator>XanthicSky</dc:creator>
<guid>http://alchemyse.wordpress.com/2013/04/05/select-element-with-jquery-where-the-id-contains-specific-text/</guid>
<description><![CDATA[I have needed to do this on occasion with long auto-generated ids. $j("[id$='logActivitiesCheckbox']]]></description>
<content:encoded><![CDATA[<p>I have needed to do this on occasion with long auto-generated ids. </p>
<p><code>$j("[id$='logActivitiesCheckbox']");</code></p>
<p>To get a WebElement object back from WebDriver I use this method:</p>
<pre>
  public WebElement getWebElementFromJquery(String jQuery) {
    WebElement jqElement = null;
    JavascriptExecutor js = (JavascriptExecutor) driver;
    String query = "return " + jQuery+ ".get(0);";
    try {
      jqElement = (WebElement) js.executeScript(query);
    } catch (Exception e) {
      logger.error("jQuery() " + e.getMessage());
    }
    return jqElement;
  }
</pre>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Two useful methods for finding elements with generic locator strings]]></title>
<link>http://alchemyse.wordpress.com/2013/04/05/two-useful-methods-for-finding-elements-with-generic-locator-strings/</link>
<pubDate>Fri, 05 Apr 2013 15:27:46 +0000</pubDate>
<dc:creator>XanthicSky</dc:creator>
<guid>http://alchemyse.wordpress.com/2013/04/05/two-useful-methods-for-finding-elements-with-generic-locator-strings/</guid>
<description><![CDATA[public WebElement findElement(String identifier) { WebElement el = null; try { if (identifier.indexO]]></description>
<content:encoded><![CDATA[<pre>  
public WebElement findElement(String identifier) {
    WebElement el = null;
    try {
      if (identifier.indexOf("//") &#62; -1) {
        el = driver.findElement(By.xpath(identifier));
      } else if (identifier.indexOf("link=") &#62; -1) {
        String linkText = identifier.split("=")[1];
        el = driver.findElement(By.linkText(linkText));
      } else if (identifier.indexOf("$") &#62; -1) {
        el = getWebElementFromJquery(identifier);
      } else if (identifier.indexOf("&#62;") &#62; -1 &#124;&#124; identifier.indexOf(".") &#62; -1) {
        el = driver.findElement(By.cssSelector(identifier));
      } else {
        el = driver.findElement(By.id(identifier));
      }
    } catch (Exception e) {
      logger.error("findElement() " + e.getMessage());
    }
    return el;
  }
</pre>
<pre> 
  public List findElements(String identifier) {
    List el = null;
    try {
      if (identifier.indexOf("//") &#62; -1) {
        el = driver.findElements(By.xpath(identifier));
      } else if (identifier.indexOf("link=") &#62; -1) {
        String linkText = identifier.split("=")[1];
        el = (List) driver.findElements(By.linkText(linkText));
      } else {
        el = driver.findElements(By.id(identifier));
      }
    } catch (Exception e) {
      logger.error("findElements() " + e.getMessage());
    }
    return el;
  }

</pre>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Find Web Element By Text]]></title>
<link>http://alchemyse.wordpress.com/2013/04/05/find-web-element-by-text/</link>
<pubDate>Fri, 05 Apr 2013 15:24:44 +0000</pubDate>
<dc:creator>XanthicSky</dc:creator>
<guid>http://alchemyse.wordpress.com/2013/04/05/find-web-element-by-text/</guid>
<description><![CDATA[A td tag with the text &#8220;Settings&#8221; for example: //td[contains(text(), 'Settings')] Anothe]]></description>
<content:encoded><![CDATA[<p>A td tag with the text &#8220;Settings&#8221; for example:</p>
<p><code>//td[contains(text(), 'Settings')]</code></p>
<p>Another example:</p>
<p><code>//div[contains(.,'Some Text')]</code></p>
<p>Sometimes there are cross-browser problems with using XPath. One solution is to get all elements with a specific tag name, and iterate through the list to match the values of specific attributes. </p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Selenium]]></title>
<link>http://drsusansolutions.wordpress.com/2013/04/04/selenium/</link>
<pubDate>Thu, 04 Apr 2013 20:03:12 +0000</pubDate>
<dc:creator>drsusansolutions</dc:creator>
<guid>http://drsusansolutions.wordpress.com/2013/04/04/selenium/</guid>
<description><![CDATA[Excerpt from Healthy Diet and Nutrition for Women Selenium is a trace mineral found in the soil, wat]]></description>
<content:encoded><![CDATA[<p><strong>Excerpt from <a href="http://www.amazon.com/Healthy-Diet-Nutrition-Women-ebook/dp/B00B777X0K/ref=sr_1_1?s=digital-text&#38;ie=UTF8&#38;qid=1365103066&#38;sr=1-1&#38;keywords=healthy+diet+and+nutrition+for+women"><em>Healthy Diet and Nutrition for Women</em></a></strong></p>
<p>Selenium<b> </b>is a trace mineral found in the soil, water and, in small amounts, in some foods. Selenium is an antioxidant and, as a result, can help protect our bodies from free radical damage. It appears to have protective benefits against the development of prostate cancer. Low selenium levels may be linked to osteoarthritis and symptoms of pain, stiffness and loss of mobility, possibility by decreasing inflammation. HIV and Crohn’s disease have been linked to low selenium levels in the body.<b> </b>I recommend taking 55 mcg to 200 mcg daily as a supplement.  Dosages above 400 mcg are considered unsafe. Food sources of<b> </b>selenium include brazil nuts, walnuts, tuna, cod, red snapper, herring, grains, beef and poultry.</p>
<p>For more information about Selenium or other minerals see <em><strong>Healthy Diet and Nutrition for Women</strong></em> available on <a href="http://www.amazon.com/Healthy-Diet-Nutrition-Women-ebook/dp/B00B777X0K/ref=sr_1_1?s=digital-text&#38;ie=UTF8&#38;qid=1365103066&#38;sr=1-1&#38;keywords=healthy+diet+and+nutrition+for+women">Amazon</a>, <a href="http://www.amazon.com/Healthy-Diet-Nutrition-Women-ebook/dp/B00B777X0K/ref=sr_1_1?s=digital-text&#38;ie=UTF8&#38;qid=1365103066&#38;sr=1-1&#38;keywords=healthy+diet+and+nutrition+for+women">Amazon Kindle</a> and <a href="http://www.wwpublishing.com/Healing_Herbs_Book_p/herbs.htm">Womens Wellness Publishing</a>.</p>
]]></content:encoded>
</item>

</channel>
</rss>
