forked from nikolay-advolodkin/dot-net-sauce
-
Notifications
You must be signed in to change notification settings - Fork 33
/
Copy pathLogoutFeature.cs
27 lines (26 loc) · 898 Bytes
/
LogoutFeature.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using FluentAssertions;
using NUnit.Framework;
using Selenium3.Nunit.Framework.BestPractices.Pages;
namespace Selenium3.Nunit.Framework.BestPractices.test
{
[TestFixture]
[TestFixtureSource(typeof(CrossBrowserData),
nameof(CrossBrowserData.LatestConfigurations))]
[Parallelizable]
public class LogoutFeature : BaseTest
{
public LogoutFeature(string browser, string version, string os) :
base(browser, version, os)
{
}
[Test]
public void ShouldBeAbleToLogOut()
{
var loginPage = new SauceDemoLoginPage(Driver);
loginPage.Open();
var productsPage = loginPage.Login("standard_user", "secret_sauce");
productsPage.Logout();
loginPage.IsLoaded.Should().BeTrue("we successfully logged out, so the login page should be visible");
}
}
}