Sha256: 995a1c27721acfff2511eadd98e8d75d7459bde2b1b7ec93b814d6b9984cc505

Contents?: true

Size: 680 Bytes

Versions: 3

Compression:

Stored size: 680 Bytes

Contents

#encoding: utf-8
require File.expand_path 'app/cases/spec_helper'

describe 'An example show you how to use lazyman' do

	before :all do
		@keyword = 'watir-webdriver'
	end

	it 'should search baidu using key word' do
		baidu_page = @navi.goto_baidu_page
		baidu_page.keyword = @keyword
		baidu_page.search_element.click
		result_page = SearchResultPage.new baidu_page.browser
		result_page.first_result.should eq 'watir-webdriver_百度百科'
	end

	it 'should have correct search result' do
		baidu_page = @navi.goto_baidu_page
		result_page = baidu_page.search_for @keyword
		result_page.first_result.should eq 'watir-webdriver_百度百科'
	end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
lazyman-0.1.2 lib/lazyman/generators/lazyman/app/cases/examples/baidu_example_spec.rb
lazyman-0.1.1 lib/lazyman/generators/lazyman/app/cases/examples/baidu_example_spec.rb
lazyman-0.1.0 lib/lazyman/generators/lazyman/app/cases/examples/baidu_example_spec.rb