Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
ethanmmay committed Jun 14, 2022
2 parents ea6655b + cef228e commit bb1b5bb
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 7 deletions.
2 changes: 1 addition & 1 deletion ConjuringTests/BasementPageObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public void ClickPiano()
PianoImage.Click();
}

public Boolean VerifyPianoAlertAppears()
public Boolean ClickPianoAlert()
{
// Waiting for Alert
WebDriverWait wait = new(_webDriver, TimeSpan.FromSeconds(10));
Expand Down
2 changes: 1 addition & 1 deletion ConjuringTests/HomePageObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public HomePageObject(IWebDriver webDriver)

private IWebElement PossessionButton => _webDriver.FindElement(By.ClassName("btn-danger"));

public void VerifyAtHomePage()
public void GoToHomePage()
{
if (_webDriver.Url != _homepageURL)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public BasementPossessionStepDefinitions(BrowserDriver browserDriver)
[Given(@"I am on conjuring site going towards Basement")]
public void GivenIAmOnConjuringSite()
{
_homePage.VerifyAtHomePage();
_homePage.GoToHomePage();
}

[When(@"I click possession for going to Basement")]
Expand Down Expand Up @@ -49,7 +49,7 @@ public void WhenIClickOnThePiano()
[Then(@"the piano alert appears")]
public void ThenThePianoAlertAppears()
{
Boolean alertAppears = _basementPage.VerifyPianoAlertAppears();
Boolean alertAppears = _basementPage.ClickPianoAlert();
alertAppears.Should().BeTrue();
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public BedroomPossessionStepDefinitions(BrowserDriver browserDriver)
[Given(@"I am on conjuring site going towards BedroomB")]
public void GivenIAmOnConjuringSite3()
{
_homePage.VerifyAtHomePage();
_homePage.GoToHomePage();
}

[When(@"I click possession for going to BedroomB")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public BedroomUnpossessedStepDefinitions(BrowserDriver browserDriver)
[Given(@"I am on conjuring site going towards BedroomG")]
public void GivenIAmOnConjuringSite3()
{
_homePage.VerifyAtHomePage();
_homePage.GoToHomePage();
}

[When(@"I click BedroomG")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public OutsidePossessionStepDefinitions(BrowserDriver browserDriver)
[Given(@"I am on conjuring site going towards Outside")]
public void GivenIAmOnConjuringSite2()
{
_homePage.VerifyAtHomePage();
_homePage.GoToHomePage();
}

[When(@"I click possession for going Outside")]
Expand Down
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## Welcome to Conjuring Tests
### This repository is for automated tests created with C# Selenium, SpecFlow and a Page-Object-Model design pattern.

You can run these tests yourself if you have Git SCM and Visual Studio installed on your computer, and you follow these next steps.

First, you will want to clone this repository to your local machine. To do this, open Command Prompt and navigate to where you want to clone the repo to. Then type "git clone https://github.com/ethanmmay/conjuring-tests"

Next, you can open Visual Studio and open the project using it's Solution (sln) file.

To run the tests, Click Test at the top of Visual Studio, then select Test Explorer. A window with a heirarchy will appear and you can click the tests you want to run and then click the run button.

0 comments on commit bb1b5bb

Please sign in to comment.