mirror of
https://github.com/fluent/fluentd-ui.git
synced 2026-05-05 10:56:11 +02:00
Update spec
Signed-off-by: Kenji Okimoto <okimoto@clear-code.com>
This commit is contained in:
parent
c34eeba2ca
commit
a279b82078
@ -35,16 +35,17 @@ describe "histories", stub: :daemon do
|
||||
|
||||
it 'show histories#show' do
|
||||
page.should have_css('h1', text: I18n.t('fluentd.settings.histories.show.page_title'))
|
||||
page.should have_text(last_backup_file.content)
|
||||
|
||||
page.should has_text?(last_backup_file.content)
|
||||
end
|
||||
|
||||
describe 'diff' do
|
||||
context 'has diff' do
|
||||
it 'shows diff between current and target' do
|
||||
page.should have_text("- type http")
|
||||
page.should have_text("+ type forward")
|
||||
page.should have_text("- port 8899")
|
||||
page.should have_text("+ port 24224")
|
||||
page.should has_text?("- type http")
|
||||
page.should has_text?("+ type forward")
|
||||
page.should has_text?("- port 8899")
|
||||
page.should has_text?("+ port 24224")
|
||||
end
|
||||
end
|
||||
|
||||
@ -64,7 +65,7 @@ describe "histories", stub: :daemon do
|
||||
|
||||
page.should have_css('h1', text: I18n.t('fluentd.settings.show.page_title'))
|
||||
page.should have_text(I18n.t('messages.config_successfully_copied', brand: 'fluentd') )
|
||||
page.should have_text(last_backup_file.content)
|
||||
page.should has_text?(last_backup_file.content)
|
||||
end
|
||||
|
||||
describe "configtest" do
|
||||
|
||||
@ -39,9 +39,10 @@ describe "running_backup", stub: :daemon do
|
||||
describe 'diff' do
|
||||
context 'has diff' do
|
||||
it 'shows diff between current and running' do
|
||||
expect(page).to have_text("- type http")
|
||||
expect(page).to have_text("- port 8899")
|
||||
expect(page).to have_text("+ Running backup file content")
|
||||
diff = page.first(".diff pre").native.inner_text
|
||||
expect(diff).to include("- type http")
|
||||
expect(diff).to include("- port 8899")
|
||||
expect(diff).to include("+ Running backup file content")
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user