Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversion error #60

Closed
KitaitiMakoto opened this issue Apr 29, 2014 · 2 comments
Closed

Conversion error #60

KitaitiMakoto opened this issue Apr 29, 2014 · 2 comments
Labels

Comments

@KitaitiMakoto
Copy link

Hi,

I found the case that transpec breaks example.

Before:

# example_spec.rb
describe Object do
  subject {Object.new}

  it do
    expect(subject).to receive(:to_s)
      .and_return {'Object'}                                                                                                                   
    expect(subject.to_s).to eq('Object')
  end
end

After execution of transpec example_spec.rb:

# example_spec.rb
describe Object do
  subject {Object.new}

  it do
    expect(subject).to receive(:to_s)
       {'Object'}
    expect(subject.to_s).to eq('Object')                                                                                                       
  end
end

Environment:

$  ruby -v
ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-linux]
$ transpec --version
1.13.0

Though this may seems arbitrary sample, I have encountered the error at an actual project: iiirc/iiirc@9e7e570

Thanks.

@yujinakayama
Copy link
Owner

Thanks for the report. I'll fix this.

@KitaitiMakoto
Copy link
Author

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants