public void TestInitialize()
 {
     _jobTitleTextBox           = new HtmlTextBoxTester(Browser, "JobTitle");
     _companyKeywordsTextBox    = new HtmlTextBoxTester(Browser, "CompanyKeywords");
     _desiredJobTitleTextBox    = new HtmlTextBoxTester(Browser, "DesiredJobTitle");
     _anyKeywordsTextBox        = new HtmlTextBoxTester(Browser, "AnyKeywords");
     _allKeywordsTextBox        = new HtmlTextBoxTester(Browser, "AllKeywords");
     _exactPhraseTextBox        = new HtmlTextBoxTester(Browser, "ExactPhrase");
     _withoutKeywordsTextBox    = new HtmlTextBoxTester(Browser, "WithoutKeywords");
     _countryDropDownList       = new HtmlDropDownListTester(Browser, "CountryId");
     _distanceTextBox           = new HtmlTextBoxTester(Browser, "Distance");
     _locationTextBox           = new HtmlTextBoxTester(Browser, "Location");
     _includeRelocatingCheckBox = new HtmlCheckBoxTester(Browser, "IncludeRelocating");
     _industriesListBox         = new HtmlListBoxTester(Browser, "IndustryIds");
     _lowerBoundTextBox         = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
     _upperBoundTextBox         = new HtmlTextBoxTester(Browser, "SalaryUpperBound");
     _availableNowCheckBox      = new HtmlCheckBoxTester(Browser, "AvailableNow");
     _activelyLookingCheckBox   = new HtmlCheckBoxTester(Browser, "ActivelyLooking");
     _openToOffersCheckBox      = new HtmlCheckBoxTester(Browser, "OpenToOffers");
     _notLookingCheckBox        = new HtmlCheckBoxTester(Browser, "NotLooking");
     _unspecifiedCheckBox       = new HtmlCheckBoxTester(Browser, "Unspecified");
     _aboriginalCheckBox        = new HtmlCheckBoxTester(Browser, "Aboriginal");
     _torresIslanderCheckBox    = new HtmlCheckBoxTester(Browser, "TorresIslander");
     _communityDropDownList     = new HtmlDropDownListTester(Browser, "CommunityId");
 }
Beispiel #2
0
        public void TestInitialize()
        {
            _contactDetailsUrl = new ReadOnlyApplicationUrl(true, "~/members/profile/contactdetails");

            _firstNameTextBox                = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox                 = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox             = new HtmlTextBoxTester(Browser, "EmailAddress");
            _secondaryEmailAddressTextBox    = new HtmlTextBoxTester(Browser, "SecondaryEmailAddress");
            _countryIdDropDownList           = new HtmlDropDownListTester(Browser, "CountryId");
            _locationTextBox                 = new HtmlTextBoxTester(Browser, "Location");
            _phoneNumberTextBox              = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _mobilePrimaryRadioButton        = new HtmlRadioButtonTester(Browser, "Mobile");
            _homePrimaryRadioButton          = new HtmlRadioButtonTester(Browser, "Home");
            _workPrimaryRadioButton          = new HtmlRadioButtonTester(Browser, "Work");
            _secondaryPhoneNumberTextBox     = new HtmlTextBoxTester(Browser, "SecondaryPhoneNumber");
            _mobileSecondaryRadioButton      = new HtmlRadioButtonTester(Browser, "SecondaryMobile");
            _homeSecondaryRadioButton        = new HtmlRadioButtonTester(Browser, "SecondaryHome");
            _workSecondaryRadioButton        = new HtmlRadioButtonTester(Browser, "SecondaryWork");
            _citizenshipTextBox              = new HtmlTextBoxTester(Browser, "Citizenship");
            _citizenRadioButton              = new HtmlRadioButtonTester(Browser, "Citizen");
            _unrestrictedWorkViasRadioButton = new HtmlRadioButtonTester(Browser, "UnrestrictedWorkVisa");
            _restrictedWorkVisaRadioButton   = new HtmlRadioButtonTester(Browser, "RestrictedWorkVisa");
            _noWorkVisaRadioButton           = new HtmlRadioButtonTester(Browser, "NoWorkVisa");
            _notApplicableRadioButton        = new HtmlRadioButtonTester(Browser, "NotApplicable");
            _aboriginalCheckBox              = new HtmlCheckBoxTester(Browser, "Aboriginal");
            _torresIslanderCheckBox          = new HtmlCheckBoxTester(Browser, "TorresIslander");
            _maleRadionButton                = new HtmlRadioButtonTester(Browser, "Male");
            _femaleRadioButton               = new HtmlRadioButtonTester(Browser, "Female");
            _dateOfBirthMonthDropDownList    = new HtmlDropDownListTester(Browser, "DateOfBirthMonth");
            _dateOfBirthYearDropDownList     = new HtmlDropDownListTester(Browser, "DateOfBirthYear");
        }
Beispiel #3
0
        public void TestInitialize()
        {
            MemberSearchHost.Stop();
            StartHosts();

            _joinUrl       = new ReadOnlyApplicationUrl(true, "~/join");
            _uploadUrl     = new ReadOnlyApplicationUrl(true, "~/api/resumes/upload");
            _parseUrl      = new ReadOnlyApplicationUrl(true, "~/api/resumes/parse");
            _activationUrl = new ReadOnlyApplicationUrl("~/accounts/activation");

            _joinFormId = "JoinForm";

            _personalDetailsFormId      = "PersonalDetailsForm";
            _firstNameTextBox           = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox            = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox        = new HtmlTextBoxTester(Browser, "EmailAddress");
            _phoneNumberTextBox         = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _mobileRadioButton          = new HtmlRadioButtonTester(Browser, "Mobile");
            _homeRadioButton            = new HtmlRadioButtonTester(Browser, "Home");
            _workRadioButton            = new HtmlRadioButtonTester(Browser, "Work");
            _passwordTextBox            = new HtmlPasswordTester(Browser, "Password");
            _confirmPasswordTextBox     = new HtmlPasswordTester(Browser, "ConfirmPassword");
            _acceptTermsCheckBox        = new HtmlCheckBoxTester(Browser, "AcceptTerms");
            _countryIdDropDownList      = new HtmlDropDownListTester(Browser, "CountryId");
            _locationTextBox            = new HtmlTextBoxTester(Browser, "Location");
            _notLookingRadioButton      = new HtmlRadioButtonTester(Browser, "NotLooking");
            _openToOffersRadioButton    = new HtmlRadioButtonTester(Browser, "OpenToOffers");
            _activelyLookingRadioButton = new HtmlRadioButtonTester(Browser, "ActivelyLooking");
            _availableNowRadioButton    = new HtmlRadioButtonTester(Browser, "AvailableNow");
            _salaryLowerBoundTextBox    = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _salaryRateYearRadioBox     = new HtmlRadioButtonTester(Browser, "SalaryRateYear");
            _salaryRateHourRadioBox     = new HtmlRadioButtonTester(Browser, "SalaryRateHour");

            _jobDetailsFormId = "JobDetailsForm";
        }
Beispiel #4
0
 public void TestInitialize()
 {
     _creditIdDropDownList = new HtmlDropDownListTester(Browser, "CreditId");
     _quantityTextBox      = new HtmlTextBoxTester(Browser, "Quantity");
     _expiryDateTextBox    = new HtmlTextBoxTester(Browser, "ExpiryDate");
     _addButton            = new HtmlButtonTester(Browser, "add");
 }
Beispiel #5
0
        private void AssertCategories(IEnumerable <Category> categories)
        {
            // Ensure all testers are visible for all regular type categories.

            var periodicCategories = from c in categories
                                     where c.Timing == Timing.Periodic
                                     select c;

            foreach (var periodicCategory in periodicCategories)
            {
                var tester = new HtmlDropDownListTester(Browser, periodicCategory.Name);
                Assert.IsTrue(tester.IsVisible);
                Assert.IsTrue(periodicCategory.AvailableFrequencies.SequenceEqual((from i in tester.Items select(Frequency) Enum.Parse(typeof(Frequency), i.Value))));
            }

            // Ensure all testers are visible for all notification type categories.

            var notificationTesters = from c in categories
                                      where c.Timing == Timing.Notification
                                      select new HtmlCheckBoxTester(Browser, c.Name);

            foreach (var tester in notificationTesters)
            {
                Assert.IsTrue(tester.IsVisible);
            }
        }
Beispiel #6
0
 protected static void ConfirmSelectedCommunity(HtmlDropDownListTester ddlCommunity, bool visible, Community community)
 {
     Assert.AreEqual(ddlCommunity, visible);
     if (visible)
     {
         Assert.AreEqual(community != null ? community.Id.ToString() : string.Empty, ddlCommunity.SelectedItem.Value);
     }
 }
 public void TestInitialize()
 {
     _fullNameTextBox = new HtmlTextBoxTester(Browser, "FullName");
     _accountManagerIdDropDownList    = new HtmlDropDownListTester(Browser, "AccountManagerId");
     _verifiedOrganisationsCheckBox   = new HtmlCheckBoxTester(Browser, "VerifiedOrganisations");
     _unverifiedOrganisationsCheckBox = new HtmlCheckBoxTester(Browser, "UnverifiedOrganisations");
     _searchButton = new HtmlButtonTester(Browser, "search");
 }
Beispiel #8
0
        public void CandidateListsTestsInitialize()
        {
            _sortOrderDropDownList            = new HtmlDropDownListTester(Browser, "SortOrder");
            _sortOrderIsAscendingRadioButton  = new HtmlRadioButtonTester(Browser, "SortOrderIsAscending");
            _sortOrderIsDescendingRadioButton = new HtmlRadioButtonTester(Browser, "SortOrderIsDescending");

            _baseBlockListsUrl = new ReadOnlyApplicationUrl(true, "~/employers/candidates/blocklists/");
        }
Beispiel #9
0
        public void TestInitialize()
        {
            _faqsUrl           = new ReadOnlyApplicationUrl("~/faqs");
            _oldFaqsUrl        = new ReadOnlyApplicationUrl("~/faq");
            _markHelpfulUrl    = new ReadOnlyApplicationUrl("~/faqs/api/helpful");
            _markNotHelpfulUrl = new ReadOnlyApplicationUrl("~/faqs/api/nothelpful");

            _categoryIdDropDownList = new HtmlDropDownListTester(Browser, "CategoryId");
        }
Beispiel #10
0
        private static void AssertTester(Frequency frequency, HtmlDropDownListTester tester)
        {
            // Assert that the tester is visible.

            Assert.IsTrue(tester.IsVisible);

            // The tester value should correspond to the frequency.

            Assert.AreEqual(frequency.ToString(), tester.SelectedItem.Text);
        }
Beispiel #11
0
        public void TestInitialize()
        {
            Resolve <IDbConnectionFactory>().DeleteAllTestData();

            _searchButton = new HtmlButtonTester(Browser, "search");

            _firstNameTextBox    = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox     = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox = new HtmlTextBoxTester(Browser, "EmailAddress");
            _countDropDownList   = new HtmlDropDownListTester(Browser, "Count");
        }
Beispiel #12
0
 protected Guid?GetSelectedProductId(HtmlDropDownListTester tester)
 {
     try
     {
         return(new Guid(tester.SelectedItem.Value));
     }
     catch (Exception)
     {
         return(null);
     }
 }
Beispiel #13
0
        public void TestInitialize()
        {
            _educationUrl = new ReadOnlyApplicationUrl(true, "~/members/profile/education");

            _highestEducationLevelDropDownList = new HtmlDropDownListTester(Browser, "HighestEducationLevel");
            _endDateMonthDropDownList          = new HtmlDropDownListTester(Browser, "EndDateMonth");
            _endDateYearDropDownList           = new HtmlDropDownListTester(Browser, "EndDateYear");
            _degreeTextBox      = new HtmlTextBoxTester(Browser, "Degree");
            _majorTextBox       = new HtmlTextBoxTester(Browser, "Major");
            _institutionTextBox = new HtmlTextBoxTester(Browser, "Institution");
            _cityTextBox        = new HtmlTextBoxTester(Browser, "City");
            _descriptionTextBox = new HtmlTextAreaTester(Browser, "Description");
        }
Beispiel #14
0
 public void TestInitialize()
 {
     _parentFullNameTextBox        = new HtmlTextBoxTester(Browser, "ParentFullName");
     _nameTextBox                  = new HtmlTextBoxTester(Browser, "Name");
     _locationTextBox              = new HtmlTextBoxTester(Browser, "Location");
     _accountManagerIdDropDownList = new HtmlDropDownListTester(Browser, "AccountManagerId");
     _firstNameTextBox             = new HtmlTextBoxTester(Browser, "FirstName");
     _lastNameTextBox              = new HtmlTextBoxTester(Browser, "LastName");
     _emailAddressTextBox          = new HtmlTextBoxTester(Browser, "EmailAddress");
     _communityIdDropDownList      = new HtmlDropDownListTester(Browser, "CommunityId");
     _saveButton   = new HtmlButtonTester(Browser, "save");
     _verifyButton = new HtmlButtonTester(Browser, "verify");
 }
Beispiel #15
0
        public void CampaignsTestsInitialize()
        {
            _campaignsUrl    = new ReadOnlyApplicationUrl(true, "~/administrators/communications/campaigns");
            _newCampaignUrl  = new ReadOnlyApplicationUrl(true, "~/administrators/communications/campaigns/campaign/new");
            _campaignUrlBase = new ReadOnlyApplicationUrl(true, "~/administrators/communications/campaigns/campaign/");

            _nameTextBox          = new HtmlTextBoxTester(Browser, "Name");
            _categoryDropDownList = new HtmlDropDownListTester(Browser, "Category");
            _communicationDefinitionDropDownList = new HtmlDropDownListTester(Browser, "CommunicationDefinitionId");
            _communicationCategoryDropDownList   = new HtmlDropDownListTester(Browser, "CommunicationCategoryId");
            _queryTextArea = new HtmlTextAreaTester(Browser, "Query");
            _saveButton    = new HtmlButtonTester(Browser, "save");
        }
Beispiel #16
0
        public void EmployerNewJobAdTestsInitialize()
        {
            Resolve <IDbConnectionFactory>().DeleteAllTestData();

            _previewButton = new HtmlButtonTester(Browser, "preview");
            _saveButton    = new HtmlButtonTester(Browser, "save");

            _publishButton = new HtmlButtonTester(Browser, "publish");
            _reopenButton  = new HtmlButtonTester(Browser, "reopen");
            _repostButton  = new HtmlButtonTester(Browser, "repost");
            _editButton    = new HtmlButtonTester(Browser, "edit");

            _titleTextBox                   = new HtmlTextBoxTester(Browser, "Title");
            _positionTitleTextBox           = new HtmlTextBoxTester(Browser, "PositionTitle");
            _externalReferenceIdTextBox     = new HtmlTextBoxTester(Browser, "ExternalReferenceId");
            _bulletPoint1TextBox            = new HtmlTextBoxTester(Browser, "BulletPoint1");
            _bulletPoint2TextBox            = new HtmlTextBoxTester(Browser, "BulletPoint2");
            _bulletPoint3TextBox            = new HtmlTextBoxTester(Browser, "BulletPoint3");
            _summaryTextBox                 = new HtmlTextAreaTester(Browser, "Summary");
            _contentTextBox                 = new HtmlTextAreaTester(Browser, "Content");
            _emailAddressTextBox            = new HtmlTextBoxTester(Browser, "EmailAddress");
            _secondaryEmailAddressesTextBox = new HtmlTextBoxTester(Browser, "SecondaryEmailAddresses");
            _phoneNumberTextBox             = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _faxNumberTextBox               = new HtmlTextBoxTester(Browser, "FaxNumber");
            _countryIdDropDownList          = new HtmlDropDownListTester(Browser, "CountryId");
            _locationTextBox                = new HtmlTextBoxTester(Browser, "Location");
            _firstNameTextBox               = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox                = new HtmlTextBoxTester(Browser, "LastName");
            _salaryLowerBoundTextBox        = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _salaryUpperBoundTextBox        = new HtmlTextBoxTester(Browser, "SalaryUpperBound");
            _packageTextBox                 = new HtmlTextBoxTester(Browser, "Package");
            _companyNameTextBox             = new HtmlTextBoxTester(Browser, "CompanyName");
            _hideCompanyCheckBox            = new HtmlCheckBoxTester(Browser, "HideCompany");
            _residencyRequiredCheckBox      = new HtmlCheckBoxTester(Browser, "ResidencyRequired");
            _industryIdsListBox             = new HtmlListBoxTester(Browser, "IndustryIds");
            _fullTimeCheckBox               = new HtmlCheckBoxTester(Browser, "FullTime");
            _partTimeCheckBox               = new HtmlCheckBoxTester(Browser, "PartTime");
            _contractCheckBox               = new HtmlCheckBoxTester(Browser, "Contract");
            _tempCheckBox                   = new HtmlCheckBoxTester(Browser, "Temp");
            _jobShareCheckBox               = new HtmlCheckBoxTester(Browser, "JobShare");
            _expiryTimeTextBox              = new HtmlTextBoxTester(Browser, "ExpiryTime");
            _hideContactDetailsCheckBox     = new HtmlCheckBoxTester(Browser, "HideContactDetails");

            _baseFeaturePack = new HtmlRadioButtonTester(Browser, "BaseFeaturePack");
            _featurePack1    = new HtmlRadioButtonTester(Browser, "FeaturePack1");
            _featurePack2    = new HtmlRadioButtonTester(Browser, "FeaturePack2");

            _accounting     = _industriesQuery.GetIndustry("Accounting");
            _administration = _industriesQuery.GetIndustry("Administration");
        }
Beispiel #17
0
        public void TestInitialize()
        {
            _contactUsUrl        = new ReadOnlyApplicationUrl("~/contactus");
            _contactUsPartialUrl = new ReadOnlyApplicationUrl("~/contactus/partial");
            _faqUrl = new ReadOnlyApplicationUrl("~/faqs/setting-up-your-profile/09d11385-0213-4157-a5a9-1b2a74e6887e");

            _siteIssueUrl = new ReadOnlyApplicationUrl("~/contactus/partial?enquiryType=Report+a+site+issue");

            _nameTextBox               = new HtmlTextBoxTester(Browser, "Name");
            _fromTextBox               = new HtmlTextBoxTester(Browser, "From");
            _phoneTextBox              = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _userTypeDropDownList      = new HtmlDropDownListTester(Browser, "UserType");
            _subcategoryIdDropDownList = new HtmlDropDownListTester(Browser, "MemberSubcategoryId");
            _messageTextBox            = new HtmlTextAreaTester(Browser, "Message");
        }
Beispiel #18
0
        public void TestInitialize()
        {
            _employmentHistoryUrl = new ReadOnlyApplicationUrl(true, "~/members/profile/employmenthistory");

            _recentProfessionDropDownList = new HtmlDropDownListTester(Browser, "RecentProfession");
            _recentSeniorityDropDownList  = new HtmlDropDownListTester(Browser, "RecentSeniority");
            _industryIdsListBox           = new HtmlListBoxTester(Browser, "IndustryIds");
            _startDateMonthDropDownList   = new HtmlDropDownListTester(Browser, "StartDateMonth");
            _startDateYearDropDownList    = new HtmlDropDownListTester(Browser, "StartDateYear");
            _endDateMonthDropDownList     = new HtmlDropDownListTester(Browser, "EndDateMonth");
            _endDateYearDropDownList      = new HtmlDropDownListTester(Browser, "EndDateYear");
            _titleTextBox       = new HtmlTextBoxTester(Browser, "Title");
            _companyTextBox     = new HtmlTextBoxTester(Browser, "Company");
            _descriptionTextBox = new HtmlTextAreaTester(Browser, "Description");
        }
Beispiel #19
0
        protected static void SetCommunity(HtmlDropDownListTester ddlCommunity, Community community)
        {
            Assert.IsTrue(ddlCommunity.IsVisible);
            Assert.AreEqual(true, ddlCommunity.IsEnabled);
            if (community != null)
            {
                // It should only be selected if it is there.

                var item = ddlCommunity.Items.SingleOrDefault(i => i.Value == community.Id.ToString());
                ddlCommunity.SelectedValue = item != null ? item.Value : string.Empty;
            }
            else
            {
                ddlCommunity.SelectedValue = string.Empty;
            }
        }
Beispiel #20
0
        public void TestInitialize()
        {
            Resolve <IDbConnectionFactory>().DeleteAllTestData();

            _landingJoinUrl       = new ReadOnlyApplicationUrl("~/landing/join.aspx");
            _landingSampleJoinUrl = new ReadOnlyApplicationUrl("~/landing/samplejoin.aspx");
            _joinUrl            = new ReadOnlyApplicationUrl(true, "~/join");
            _personalDetailsUrl = new ReadOnlyApplicationUrl(true, "~/join/personaldetails");
            _jobDetailsUrl      = new ReadOnlyApplicationUrl(true, "~/join/jobdetails");
            _activateUrl        = new ReadOnlyApplicationUrl(true, "~/join/activate");

            _txtFirstName = new HtmlTextBoxTester(Browser, "ctl00_Body_ucJoin_txtFirstName");
            _txtLastName  = new HtmlTextBoxTester(Browser, "ctl00_Body_ucJoin_txtLastName");
            _txtEmail     = new HtmlTextBoxTester(Browser, "ctl00_Body_ucJoin_txtEmail");
            _txtPassword  = new HtmlPasswordTester(Browser, "ctl00_Body_ucJoin_txtPassword");
            _chkAcceptTermsAndConditions = new HtmlCheckBoxTester(Browser, "ctl00_Body_ucJoin_chkAcceptTermsAndConditions", false);
            _btnJoin = new HtmlButtonTester(Browser, "ctl00_Body_btnJoin");

            // To make it portable, names on the sample form are prefixed by "linkme_".
            // (Portable = may be copied to and used on other websites)
            //
            _txtSampleFirstName = new HtmlTextBoxTester(Browser, "linkme_txtFirstName");
            _txtSampleLastName  = new HtmlTextBoxTester(Browser, "linkme_txtLastName");
            _txtSampleEmail     = new HtmlTextBoxTester(Browser, "linkme_txtUsername");
            _txtSamplePassword  = new HtmlPasswordTester(Browser, "linkme_txtPassword");
            _chkSampleAcceptTermsAndConditions = new HtmlCheckBoxTester(Browser, "linkme_chkAcceptTermsAndConditions", false);
            _btnSampleJoin = new HtmlButtonTester(Browser, "linkme_btnJoin");

            _joinFormId = "JoinForm";

            _personalDetailsFormId   = "PersonalDetailsForm";
            _firstNameTextBox        = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox         = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox     = new HtmlTextBoxTester(Browser, "EmailAddress");
            _phoneNumberTextBox      = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _passwordTextBox         = new HtmlTextBoxTester(Browser, "Password");
            _confirmPasswordTextBox  = new HtmlTextBoxTester(Browser, "ConfirmPassword");
            _acceptTermsCheckBox     = new HtmlCheckBoxTester(Browser, "AcceptTerms");
            _locationTextBox         = new HtmlTextBoxTester(Browser, "Location");
            _salaryLowerBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _openToOffersRadioButton = new HtmlRadioButtonTester(Browser, "OpenToOffers");

            _jobDetailsFormId             = "JobDetailsForm";
            _maleRadioButton              = new HtmlRadioButtonTester(Browser, "Male");
            _dateOfBirthMonthDropDownList = new HtmlDropDownListTester(Browser, "DateOfBirthMonth");
            _dateOfBirthYearDropDownList  = new HtmlDropDownListTester(Browser, "DateOfBirthYear");
        }
Beispiel #21
0
        protected static void ConfirmCommunities(HtmlDropDownListTester ddlCommunity, params Community[] communities)
        {
            Assert.AreEqual(communities.Length + 1, ddlCommunity.Items.Count);
            foreach (var community in communities)
            {
                var found = false;
                foreach (var item in ddlCommunity.Items)
                {
                    if (item.Value == community.Id.ToString())
                    {
                        found = true;
                        break;
                    }
                }

                Assert.IsTrue(found);
            }
        }
Beispiel #22
0
        public void ProductsTestsInitialize()
        {
            _newOrderUrl = new ReadOnlyApplicationUrl(true, "~/employers/products/neworder");
            _chooseUrl   = new ReadOnlyApplicationUrl(true, "~/employers/products/choose");
            _accountUrl  = new ReadOnlyApplicationUrl(true, "~/employers/products/account");
            _paymentUrl  = new ReadOnlyApplicationUrl(true, "~/employers/products/payment");
            _receiptUrl  = new ReadOnlyApplicationUrl(true, "~/employers/products/receipt");
            _creditsUrl  = new ReadOnlyApplicationUrl(true, "~/employers/products/credits");
            _ordersUrl   = new ReadOnlyApplicationUrl(true, "~/employers/products/orders");
            _orderUrl    = new ReadOnlyApplicationUrl(true, "~/employers/products/order");
            _searchUrl   = new ReadOnlyApplicationUrl(true, "~/search/candidates");

            _joinButton     = new HtmlButtonTester(Browser, "join");
            _loginButton    = new HtmlButtonTester(Browser, "login");
            _purchaseButton = new HtmlButtonTester(Browser, "purchase");
            _backButton     = new HtmlButtonTester(Browser, "back");
            _cancelButton   = new HtmlButtonTester(Browser, "cancel");

            _contactProductIdDropDownList = new HtmlDropDownListTester(Browser, "ContactProductId");

            _loginIdTextBox     = new HtmlTextBoxTester(Browser, "LoginId");
            _passwordTextBox    = new HtmlPasswordTester(Browser, "Password");
            _rememberMeCheckBox = new HtmlCheckBoxTester(Browser, "RememberMe");

            _joinLoginIdTextBox         = new HtmlTextBoxTester(Browser, "JoinLoginId");
            _joinPasswordTextBox        = new HtmlPasswordTester(Browser, "JoinPassword");
            _joinConfirmPasswordTextBox = new HtmlPasswordTester(Browser, "JoinConfirmPassword");
            _firstNameTextBox           = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox            = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox        = new HtmlTextBoxTester(Browser, "EmailAddress");
            _phoneNumberTextBox         = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _organisationNameTextBox    = new HtmlTextBoxTester(Browser, "OrganisationName");
            _locationTextBox            = new HtmlTextBoxTester(Browser, "Location");
            _acceptTermsCheckBox        = new HtmlCheckBoxTester(Browser, "AcceptTerms");

            _cardNumberTextBox           = new HtmlTextBoxTester(Browser, "CardNumber");
            _cvvTextBox                  = new HtmlTextBoxTester(Browser, "Cvv");
            _cardHolderNameTextBox       = new HtmlTextBoxTester(Browser, "CardHolderName");
            _cardTypeDropDownList        = new HtmlDropDownListTester(Browser, "CardType");
            _expiryMonthDropDownList     = new HtmlDropDownListTester(Browser, "ExpiryMonth");
            _expiryYearDropDownList      = new HtmlDropDownListTester(Browser, "ExpiryYear");
            _authoriseCreditCardCheckBox = new HtmlCheckBoxTester(Browser, "authoriseCreditCard");
        }
Beispiel #23
0
        private void UpdatePeriodicCategory(ref RecipientSettings settings, Category category, Frequency newFrequency, bool updateSettings)
        {
            var frequency = GetFrequency(category, settings);

            // Check the correct frequency is being shown and that it will be changed.

            var tester = new HtmlDropDownListTester(Browser, category.Name);

            Assert.AreEqual(frequency.ToString(), tester.SelectedItem.Text);
            Assert.IsTrue(frequency != newFrequency);

            // Update the selected item.

            tester.SelectedValue = newFrequency.ToString();

            if (updateSettings)
            {
                UpdateSettings(ref settings, category, newFrequency);
            }
        }
Beispiel #24
0
        public void TestInitialize()
        {
            Resolve <IDbConnectionFactory>().DeleteAllTestData();
            _emailServer.ClearEmails();

            // Join.

            _joinFormId = "JoinForm";

            _personalDetailsFormId   = "PersonalDetailsForm";
            _firstNameTextBox        = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox         = new HtmlTextBoxTester(Browser, "LastName");
            _emailAddressTextBox     = new HtmlTextBoxTester(Browser, "EmailAddress");
            _phoneNumberTextBox      = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _passwordTextBox         = new HtmlPasswordTester(Browser, "Password");
            _confirmPasswordTextBox  = new HtmlPasswordTester(Browser, "ConfirmPassword");
            _acceptTermsCheckBox     = new HtmlCheckBoxTester(Browser, "AcceptTerms");
            _locationTextBox         = new HtmlTextBoxTester(Browser, "Location");
            _salaryLowerBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _openToOffersRadioButton = new HtmlRadioButtonTester(Browser, "OpenToOffers");

            _jobDetailsFormId             = "JobDetailsForm";
            _maleRadioButton              = new HtmlRadioButtonTester(Browser, "Male");
            _dateOfBirthMonthDropDownList = new HtmlDropDownListTester(Browser, "DateOfBirthMonth");
            _dateOfBirthYearDropDownList  = new HtmlDropDownListTester(Browser, "DateOfBirthYear");

            // InviteContactsForm

            _txtEmailAddresses  = new HtmlTextAreaTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFriends_txtEmailAddresses");
            _btnSendInvitations = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnSendInvitations");

            // ReceivedInvitiationsFrom

            _btnAccept = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_LeftContent") + "_ucReceivedNetworkInvitationList_rptInvitations_ctl00_btnAccept");

            _joinUrl     = new ReadOnlyApplicationUrl(true, "~/join");
            _activateUrl = new ReadOnlyApplicationUrl(true, "~/join/activate");
            _profileUrl  = new ReadOnlyApplicationUrl(true, "~/members/profile");
        }
Beispiel #25
0
        public void MobileSearchTestsInitialize()
        {
            Browser.UseMobileUserAgent = true;

            _allWordsTextBox = new HtmlTextBoxTester(Browser, "KeywordsAdvanced");
            _searchButton    = new HtmlButtonTester(Browser, "searchAdvanced");

            _keywordsTextBox         = new HtmlTextAreaTester(Browser, "Keywords");
            _adTitleTextBox          = new HtmlTextAreaTester(Browser, "AdTitle");
            _advertiserTextBox       = new HtmlTextBoxTester(Browser, "Advertiser");
            _salaryLowerBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _salaryUpperBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryUpperBound");

            _locationTextBox      = new HtmlTextBoxTester(Browser, "Location");
            _distanceDropDownList = new HtmlDropDownListTester(Browser, "Distance");
            _distanceTextBox      = new HtmlTextBoxTester(Browser, "Distance");

            _sortOrderDropDownList = new HtmlDropDownListTester(Browser, "SortOrder");

            _includeSynonymsTextBox = new HtmlHiddenTester(Browser, "IncludeSynonyms");

            _recencyTextBox = new HtmlTextBoxTester(Browser, "Recency");

            _hasAppliedEitherRadioButton = new HtmlRadioButtonTester(Browser, "HasAppliedEither");
            _hasAppliedYesRadioButton    = new HtmlRadioButtonTester(Browser, "HasAppliedYes");
            _hasAppliedNoRadioButton     = new HtmlRadioButtonTester(Browser, "HasAppliedNo");

            _isFlaggedEitherRadioButton = new HtmlRadioButtonTester(Browser, "IsFlaggedEither");
            _isFlaggedYesRadioButton    = new HtmlRadioButtonTester(Browser, "IsFlaggedYes");
            _isFlaggedNoRadioButton     = new HtmlRadioButtonTester(Browser, "IsFlaggedNo");

            _hasNotesEitherRadioButton = new HtmlRadioButtonTester(Browser, "HasNotesEither");
            _hasNotesYesRadioButton    = new HtmlRadioButtonTester(Browser, "HasNotesYes");
            _hasNotesNoRadioButton     = new HtmlRadioButtonTester(Browser, "HasNotesNo");

            _hasViewedEitherRadioButton = new HtmlRadioButtonTester(Browser, "HasViewedEither");
            _hasViewedYesRadioButton    = new HtmlRadioButtonTester(Browser, "HasViewedYes");
            _hasViewedNoRadioButton     = new HtmlRadioButtonTester(Browser, "HasViewedNo");
        }
Beispiel #26
0
        public void TestInitialize()
        {
            _loginIdTextBox         = new HtmlTextBoxTester(Browser, "LoginId");
            _emailAddressTextBox    = new HtmlTextBoxTester(Browser, "EmailAddress");
            _firstNameTextBox       = new HtmlTextBoxTester(Browser, "FirstName");
            _lastNameTextBox        = new HtmlTextBoxTester(Browser, "LastName");
            _phoneNumberTextBox     = new HtmlTextBoxTester(Browser, "PhoneNumber");
            _jobTitleTextBox        = new HtmlTextBoxTester(Browser, "JobTitle");
            _industryIdDropDownList = new HtmlDropDownListTester(Browser, "IndustryId");

            _createButton = new HtmlButtonTester(Browser, "create");
            _cancelButton = new HtmlButtonTester(Browser, "cancel");

            _passwordTextBox           = new HtmlPasswordTester(Browser, "Password");
            _newPasswordTextBox        = new HtmlPasswordTester(Browser, "NewPassword");
            _confirmNewPasswordTextBox = new HtmlPasswordTester(Browser, "ConfirmNewPassword");
            _saveButton = new HtmlButtonTester(Browser, "save");

            _mustChangePasswordUrl = new ReadOnlyApplicationUrl(true, "~/accounts/mustchangepassword");

            _emailServer.ClearEmails();
        }
Beispiel #27
0
        public void TestInitialize()
        {
            _btnFindFriends       = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnFindFriends");
            _btnCancelFindFriends = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnCancelFindFriends");

            _btnAddToInvitation       = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnAddToInvitation");
            _btnCancelAddToInvitation = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnCancelAddToInvitation");

            _btnSendInvitations       = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnSendInvitations");
            _btnCancelSendInvitations = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnCancelSendInvitations");

            _btnUploadCsv       = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnUploadCsv");
            _btnCancelUploadCsv = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnCancelUploadCsv");

            _btnNetworkInvite       = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnNetworkInvite");
            _btnCancelNetworkInvite = new HtmlButtonTester(Browser, AddBodyPrefix("FormContent_Content") + "_btnCancelNetworkInvite");

            _txtEmailAddress     = new HtmlTextBoxTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFromAddressBook_txtEmailAddress");
            _txtProviderPassword = new HtmlPasswordTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFromAddressBook_txtPassword");
            _ddlProviders        = new HtmlDropDownListTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFromAddressBook_ddlProviders");

            _txtFilePath = new HtmlFileTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteEmailClientContacts_txtFilePath");

            _txtEmailAddresses    = new HtmlTextAreaTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFriends_txtEmailAddresses");
            _txtBody              = new HtmlTextAreaTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFriends_txtBody");
            _chkDonationRecipient = new HtmlCheckBoxTester(Browser, AddBodyPrefix("FormContent_Content") + "_ucInviteFriends_chkDonationRecipient");

            _loginIdTextBox  = new HtmlTextBoxTester(Browser, "LoginId");
            _passwordTextBox = new HtmlPasswordTester(Browser, "Password");
            _loginButton     = new HtmlButtonTester(Browser, "login");

            Resolve <IDbConnectionFactory>().DeleteAllTestData();
            _emailServer.ClearEmails();

            _activationUrl   = new ReadOnlyApplicationUrl("~/accounts/activation");
            _notActivatedUrl = new ReadOnlyApplicationUrl(true, "~/accounts/notactivated");
        }
Beispiel #28
0
 public void TestInitialize()
 {
     _aimeMemberStatusDropDownList = new HtmlDropDownListTester(Browser, "AimeMemberStatus");
 }
Beispiel #29
0
        public void SearchTestsInitialize()
        {
            ClearSearchIndexes();

            _candidatesUrl      = new ReadOnlyApplicationUrl(true, "~/employers/candidates");
            _searchUrl          = new ReadOnlyApplicationUrl(true, "~/search/candidates");
            _resultsUrl         = new ReadOnlyApplicationUrl("~/search/candidates/results");
            _partialSearchUrl   = new ReadOnlyApplicationUrl("~/search/candidates/partial");
            _baseSavedSearchUrl = new ReadOnlyApplicationUrl("~/search/candidates/saved/");

            _keywordsTextBox        = new HtmlTextBoxTester(Browser, "Keywords");
            _allKeywordsTextBox     = new HtmlTextBoxTester(Browser, "AllKeywords");
            _exactPhraseTextBox     = new HtmlTextBoxTester(Browser, "ExactPhrase");
            _anyKeywordsTester      = new AnyKeywordsTester(Browser, "AnyKeywords1", "AnyKeywords2", "AnyKeywords3");
            _withoutKeywordsTextBox = new HtmlTextBoxTester(Browser, "WithoutKeywords");

            _availableNowCheckBox    = new HtmlCheckBoxTester(Browser, "AvailableNow");
            _activelyLookingCheckBox = new HtmlCheckBoxTester(Browser, "ActivelyLooking");
            _openToOffersCheckBox    = new HtmlCheckBoxTester(Browser, "OpenToOffers");
            _unspecifiedCheckBox     = new HtmlCheckBoxTester(Browser, "Unspecified");

            _fullTimeCheckBox = new HtmlCheckBoxTester(Browser, "FullTime");
            _partTimeCheckBox = new HtmlCheckBoxTester(Browser, "PartTime");
            _contractCheckBox = new HtmlCheckBoxTester(Browser, "Contract");
            _tempCheckBox     = new HtmlCheckBoxTester(Browser, "Temp");
            _jobShareCheckBox = new HtmlCheckBoxTester(Browser, "JobShare");

            _educationKeywordsTextBox = new HtmlTextBoxTester(Browser, "EducationKeywords");

            _allIndustriesCheckBox = new HtmlCheckBoxTester(Browser, "all-industries");
            _industryIdCheckBoxes  = new List <HtmlCheckBoxTester>();
            for (var index = 0; index < _industriesQuery.GetIndustries().Count; ++index)
            {
                _industryIdCheckBoxes.Add(new HtmlCheckBoxTester(Browser, "industry" + index));
            }

            _searchByNameTextBox            = new HtmlTextBoxTester(Browser, "CandidateName");
            _exactMatchNameRadioButton      = new HtmlRadioButtonTester(Browser, "ExactMatch");
            _includeSimilarNamesRadioButton = new HtmlRadioButtonTester(Browser, "CloseMatch");

            _jobTitleTextBox        = new HtmlTextBoxTester(Browser, "JobTitle");
            _desiredJobTitleTextBox = new HtmlTextBoxTester(Browser, "DesiredJobTitle");
            _recentJobsRadioButton  = new HtmlRadioButtonTester(Browser, "RecentJobs");
            _allJobsRadioButton     = new HtmlRadioButtonTester(Browser, "AllJobs");

            _companyKeywordsTextBox     = new HtmlTextBoxTester(Browser, "CompanyKeywords");
            _recentCompaniesRadioButton = new HtmlRadioButtonTester(Browser, "RecentCompanies");
            _allCompaniesRadioButton    = new HtmlRadioButtonTester(Browser, "AllCompanies");
            _lastCompanyRadioButton     = new HtmlRadioButtonTester(Browser, "LastCompany");

            _locationTextBox                    = new HtmlTextBoxTester(Browser, "Location");
            _countryIdDropDownList              = new HtmlDropDownListTester(Browser, "CountryId");
            _distanceDropDownList               = new HtmlDropDownListTester(Browser, "Distance");
            _includeRelocatingCheckBox          = new HtmlCheckBoxTester(Browser, "IncludeRelocating");
            _includeInternationalCheckBox       = new HtmlCheckBoxTester(Browser, "IncludeInternational");
            _includeRelocatingFilterCheckBox    = new HtmlCheckBoxTester(Browser, "IncludeRelocatingFilter");
            _includeInternationalFilterCheckBox = new HtmlCheckBoxTester(Browser, "IncludeInternationalFilter");

            _sortOrderDropDownList            = new HtmlDropDownListTester(Browser, "SortOrder");
            _sortOrderIsAscendingRadioButton  = new HtmlRadioButtonTester(Browser, "SortOrderIsAscending");
            _sortOrderIsDescendingRadioButton = new HtmlRadioButtonTester(Browser, "SortOrderIsDescending");

            _includeSynonymsTextBox = new HtmlHiddenTester(Browser, "IncludeSynonyms");

            _recencyTextBox = new HtmlTextBoxTester(Browser, "Recency");

            _salaryLowerBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryLowerBound");
            _salaryUpperBoundTextBox = new HtmlTextBoxTester(Browser, "SalaryUpperBound");

            _inFolderEitherRadioButton = new HtmlRadioButtonTester(Browser, "InFolderEither");
            _inFolderYesRadioButton    = new HtmlRadioButtonTester(Browser, "InFolderYes");
            _inFolderNoRadioButton     = new HtmlRadioButtonTester(Browser, "InFolderNo");

            _isFlaggedEitherRadioButton = new HtmlRadioButtonTester(Browser, "IsFlaggedEither");
            _isFlaggedYesRadioButton    = new HtmlRadioButtonTester(Browser, "IsFlaggedYes");
            _isFlaggedNoRadioButton     = new HtmlRadioButtonTester(Browser, "IsFlaggedNo");

            _hasNotesEitherRadioButton = new HtmlRadioButtonTester(Browser, "HasNotesEither");
            _hasNotesYesRadioButton    = new HtmlRadioButtonTester(Browser, "HasNotesYes");
            _hasNotesNoRadioButton     = new HtmlRadioButtonTester(Browser, "HasNotesNo");

            _hasViewedEitherRadioButton = new HtmlRadioButtonTester(Browser, "HasViewedEither");
            _hasViewedYesRadioButton    = new HtmlRadioButtonTester(Browser, "HasViewedYes");
            _hasViewedNoRadioButton     = new HtmlRadioButtonTester(Browser, "HasViewedNo");

            _isUnlockedEitherRadioButton = new HtmlRadioButtonTester(Browser, "IsUnlockedEither");
            _isUnlockedYesRadioButton    = new HtmlRadioButtonTester(Browser, "IsUnlockedYes");
            _isUnlockedNoRadioButton     = new HtmlRadioButtonTester(Browser, "IsUnlockedNo");

            _ethnicStatusCheckBox   = new HtmlCheckBoxTester(Browser, "EthnicStatus");
            _aboriginalCheckBox     = new HtmlCheckBoxTester(Browser, "Aboriginal");
            _torresIslanderCheckBox = new HtmlCheckBoxTester(Browser, "TorresIslander");

            _visaStatusCheckBox           = new HtmlCheckBoxTester(Browser, "VisaStatus");
            _citizenCheckBox              = new HtmlCheckBoxTester(Browser, "Citizen");
            _unrestrictedWorkVisaCheckBox = new HtmlCheckBoxTester(Browser, "UnrestrictedWorkVisa");
            _restrictedWorkVisaCheckBox   = new HtmlCheckBoxTester(Browser, "RestrictedWorkVisa");
            _noWorkVisaCheckBox           = new HtmlCheckBoxTester(Browser, "NoWorkVisa");

            _communityIdDropDownList = new HtmlDropDownListTester(Browser, "CommunityId");

            _searchButton = new HtmlButtonTester(Browser, "search");
        }
Beispiel #30
0
 public void JobAdListTestInitialize()
 {
     _sortOrderDropDownList    = new HtmlDropDownListTester(Browser, "SortOrder");
     _itemsPerPageDropDownList = new HtmlDropDownListTester(Browser, "ItemsPerPage");
 }