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

Reviewed Method Access Control. #17

Merged
merged 1 commit into from Jan 8, 2014
Merged

Reviewed Method Access Control. #17

merged 1 commit into from Jan 8, 2014

Conversation

shun159
Copy link
Member

@shun159 shun159 commented Jan 1, 2014

※この意図としては、rake yard:list_undocから
内部でしか使っていないメソッドを除外させるためです。

一旦、ICMPクラスについて、
下記のメソッドをprivateに入れました。

  • Icmp::Frame
    下記以外のメソッド
    • ip_sum
    • ip_packet_length
    • icmp_sum
    • echo_data_length
    • message_type
    • to_binary
  • Icmp::Message
    • create_from
  • Pio::MessageUtil
    • option_hash

問題などございましたら、ご指摘お願い致します。
宜しくお願いします。

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.0%) when pulling 1f60b9c on shun159:develop into e4b9d99 on trema:develop.

@yasuhito
Copy link
Member

yasuhito commented Jan 7, 2014

Ruby1.8 でエラーが出ているようです。https://travis-ci.org/trema/pio/builds/16219927
rake portability:1.8.7 してそちらの手元でも再現するか確認してもらえますか?

@ghost ghost assigned yasuhito Jan 7, 2014
@shun159
Copy link
Member Author

shun159 commented Jan 7, 2014

私の環境ではこうなりました。
同じエラーは出力されません。
https://gist.github.com/shun159/8293763

蛇足かと存じますが、
下記で同じ問題が出ているようです。
無関係でしたら申し訳ありません。
rubygems/bundler#2784

@shun159
Copy link
Member Author

shun159 commented Jan 7, 2014

#ip_sum と #to_binary を public にした理由は何ですか?

#ip_sumはpublicでないとエラーになるようでした。
4) Pio::Icmp::Request.new with an emply :echo_data #to_binary returns an ICMP request binary string
Failure/Error: expect(subject.to_binary.unpack('C*')).to eq valid_icmp_request_dump
NoMethodError:
undefined method ip_sum' for #<BinData::LazyEvaluator:0x000000024fbf08> # ./lib/pio/icmp/frame.rb:19:inblock in class:Frame'
# ./lib/pio/icmp/frame.rb:59:in to_binary' # ./spec/pio/icmp/request_spec.rb:120:inblock (5 levels) in <top (required)>'

#to_binaryはprivateにいれても問題なさそうでした。

有難う御座います。

yasuhito added a commit that referenced this pull request Jan 8, 2014
Reviewed Method Access Control.
@yasuhito yasuhito merged commit 45bfc1d into trema:develop Jan 8, 2014
@yasuhito
Copy link
Member

yasuhito commented Jan 8, 2014

とりあえずマージしてみましたが、やはり Travis で 1.8 だけエラーが出ているようです。
https://travis-ci.org/trema/pio/jobs/16219928

bundler のバージョンの相性かもしれません。何か分かったら教えてください。

@yasuhito
Copy link
Member

yasuhito commented Jan 8, 2014

3a18e1e で直りました。

@shun159
Copy link
Member Author

shun159 commented Jan 8, 2014

有難う御座います。
お手数をお掛けしました。

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.

None yet

3 participants