示例#1
0
 public static void AssemblyInitialize(TestContext context)
 {
     InitialiseContainer();
     ApplicationContext.SetupApplications(WebSite.Integration);
     JobAdSearchHost.Start();
     JobAdSortHost.Start();
 }
示例#2
0
        public static void ClassInitialize(TestContext context)
        {
            Resolve <IDbConnectionFactory>().DeleteAllTestData();
            JobAdSortHost.ClearIndex();

            _sortService = Resolve <IJobAdSortService>();
        }
示例#3
0
        public void TestInitialize()
        {
            JobAdSearchHost.Stop();
            JobAdSortHost.Stop();
            StartSearchHosts();
            StartSortHosts();

            _titleTextBox               = new HtmlTextBoxTester(Browser, "Title");
            _positionTitleTextBox       = new HtmlTextBoxTester(Browser, "PositionTitle");
            _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");
            _locationTextBox            = new HtmlTextBoxTester(Browser, "Location");
            _companyNameTextBox         = new HtmlTextBoxTester(Browser, "CompanyName");
            _residencyRequiredCheckBox  = new HtmlCheckBoxTester(Browser, "ResidencyRequired");
            _industryIdsListBox         = new HtmlListBoxTester(Browser, "IndustryIds");
            _fullTimeCheckBox           = new HtmlCheckBoxTester(Browser, "FullTime");
            _hideContactDetailsCheckBox = new HtmlCheckBoxTester(Browser, "HideContactDetails");

            _previewButton = new HtmlButtonTester(Browser, "preview");
            _publishButton = new HtmlButtonTester(Browser, "publish");

            _newJobAdUrl = new ReadOnlyApplicationUrl(true, "~/employers/jobads/jobad");
        }
示例#4
0
 public void TestCleanup()
 {
     StopSortHosts();
     StopSearchHosts();
     JobAdSortHost.Start();
     JobAdSearchHost.Start();
 }
示例#5
0
 public static void AssemblyInitialize(TestContext context)
 {
     InitialiseContainer();
     TestApplicationContext.SetupApplications(WebSite.LinkMe);
     MemberSearchHost.Start();
     JobAdSearchHost.Start();
     JobAdSortHost.Start();
 }
 public void EmailJobSearchAlertsTaskTestsInitialize()
 {
     ServicePointManager.ServerCertificateValidationCallback = delegate { return(true); };
     Resolve <IDbConnectionFactory>().DeleteAllTestData();
     _emailServer.ClearEmails();
     JobAdSearchHost.ClearIndex();
     JobAdSortHost.ClearIndex();
 }
示例#7
0
 protected override void FixtureSetUp()
 {
     base.FixtureSetUp();
     ApplicationContext.SetupApplications(WebSite.Api);
     MemberSearchHost.Start();
     JobAdSearchHost.Start();
     JobAdSortHost.Start();
     JobAdSentimentAnalysisHost.Start();
 }
示例#8
0
文件: Main.cs 项目: formist/LinkMe
        private void Stop()
        {
            try
            {
                MemberSearchHost.Stop();
                JobAdSearchHost.Stop();
                JobAdSortHost.Stop();
                ResourceSearchHost.Stop();

                chkSynchroniseIndex.Enabled = true;
                chkRebuildIndex.Enabled     = true;
                btnStart.Enabled            = true;
                btnStop.Enabled             = false;
            }
            catch (Exception ex)
            {
                new ExceptionDialog(ex, "Exception").ShowDialog();
            }
        }
示例#9
0
        private void MapProductionFeed(string file, bool saveParsedData)
        {
            if (saveParsedData)
            {
                JobAdSearchHost.Start();
                JobAdSortHost.Start();
            }

            const string postId            = "123456";
            var          jobPosterId       = new Guid("D12C0E2E-E464-491C-96D2-15D79F98E506");
            var          integrationUserId = _careerOneQuery.GetIntegratorUser().Id;

            var posts = GetJobFeed(file);
            IJobFeedMapper <Job> mapper = new JobAdMapper(_locationQuery, _industriesQuery, null);

            foreach (var post in posts)
            {
                var jobAd = new JobAd
                {
                    PosterId    = jobPosterId,
                    Integration =
                    {
                        IntegratorReferenceId = postId,
                        ExternalApplyUrl      = string.Format("http://jobview.careerone.com.au/GetJob.aspx?JobID={0}", postId),
                        IntegratorUserId      = integrationUserId,
                    },
                };
                mapper.ApplyPostData(post, jobAd);

                if (saveParsedData)
                {
                    _jobAdsCommand.CreateJobAd(jobAd);
                    _jobAdsCommand.OpenJobAd(jobAd);
                }
            }
        }
示例#10
0
        private void MapProductionFeed(string file, bool saveParsedData)
        {
            if (saveParsedData)
            {
                JobAdSearchHost.Start();
                JobAdSortHost.Start();
            }

            const string postId            = "123456";
            var          jobPosterId       = CreateEmployer(0).Id;
            var          integrationUserId = _jxtQuery.GetIntegratorUser().Id;

            var posts = GetJobFeed(file);
            IJobFeedMapper <Job> mapper = new JobAdMapper(_locationQuery, _industriesQuery, null);

            foreach (var post in posts)
            {
                var jobAd = new JobAd
                {
                    PosterId    = jobPosterId,
                    Integration =
                    {
                        IntegratorReferenceId = postId,
                        ExternalApplyUrl      = post.ApplicationMethod.Value,
                        IntegratorUserId      = integrationUserId,
                    },
                };
                mapper.ApplyPostData(post, jobAd);

                if (saveParsedData)
                {
                    _jobAdsCommand.CreateJobAd(jobAd);
                    _jobAdsCommand.OpenJobAd(jobAd);
                }
            }
        }
示例#11
0
 public static void AssemblyInitialize(TestContext context)
 {
     InitialiseContainer();
     JobAdSearchHost.Start();
     JobAdSortHost.Start();
 }
示例#12
0
 public void ResultsTestsInitialize()
 {
     JobAdSearchHost.ClearIndex();
     JobAdSortHost.ClearIndex();
 }
示例#13
0
 protected void ClearSearchIndexes()
 {
     MemberSearchHost.ClearIndex();
     JobAdSearchHost.ClearIndex();
     JobAdSortHost.ClearIndex();
 }
示例#14
0
 public void TestInitialize()
 {
     JobAdSearchHost.Start();
     JobAdSortHost.Start();
     JobAdSentimentAnalysisHost.Start();
 }
示例#15
0
 public void TestInitialize()
 {
     Resolve <IDbConnectionFactory>().DeleteAllTestData();
     JobAdSortHost.ClearIndex();
 }
示例#16
0
 public void WebServiceTestsInitialize()
 {
     JobAdSearchHost.ClearIndex();
     JobAdSortHost.ClearIndex();
 }