Skip to content

fix regex and test error#554

Open
dadez73 wants to merge 6 commits into
voxpupuli:masterfrom
dadez73:fix-regex
Open

fix regex and test error#554
dadez73 wants to merge 6 commits into
voxpupuli:masterfrom
dadez73:fix-regex

Conversation

@dadez73
Copy link
Copy Markdown

@dadez73 dadez73 commented Oct 11, 2024

Pull Request (PR) description

This should fix the automatic test regex. and the cutted char in the config

This Pull Request (PR) fixes the following issues

#536

Comment thread lib/puppet/provider/cs_clone/pcs.rb Outdated

doc.root.attributes['id'] = id
cmd = [command(:cibadmin), '--replace', '--xpath', xpath, '--xml-text', doc.to_s.chop]
cmd = [command(:cibadmin), '--replace', '--xpath', xpath, '--xml-text', doc.to_s]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

which errors did that cause? Maybe this was meant to be chomp. not chop?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i agree chomp is the best solution! i it was cutting in half a new line.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh you did find that also. wasn't aware of it

Comment thread spec/classes/corosync_spec.rb Outdated
it 'configures votequorum' do
is_expected.to contain_file('/etc/corosync/corosync.conf').with_content(
%r{nodelist}
%r{nodelist\s*\{}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if those additional regular expressions provide any value? Do you think the original tests weren't sufficient enough, or did they cause problems?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not really add value, just checking whole line.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants