ホーム > 今日のテストコード > rspecのincludeマッチャ

rspecのincludeマッチャ

rspecのincludeマッチャ。Hashの場合の挙動はバージョン間で色々と違いがありますね。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
require 'rubygems'
gem 'rspec', '>= 1.1.12'
require 'spec'
 
describe 'includeマッチャ' do
 
  before :each do
    @lang_authors = { 
      :ruby => 'まつもとゆきひろ',
      :python => 'Guido van Rossum',
      :perl => 'Larry Wall'
    }
  end
 
  it 'Hashが指定されたキーを持つか' do
    # 以下はrspec 1.1.10, 1.1.11 でエラーになる
    @lang_authors.should include(:ruby)
    @lang_authors.should include(:python)
    @lang_authors.should_not include(:vb)
  end
 
  it 'Hashが指定されたキーと値の組み合わせを持つか' do
    # 以下はrspec 1.1.10より前だと失敗する
    @lang_authors.should include(:ruby => 'まつもとゆきひろ')
    @lang_authors.should_not include(:ruby => 'まつもとひろゆき')
  end
 
  it 'その他はinclude?による評価' do
    @lang_authors[:python].should include('os')
    @lang_authors.keys.should include(:perl)
  end
 
end

参考:

  1. 2020 年 8 月 1 日 17:00 | #1

    I’m impressed, I have to admit. Rarely do I encounter a blog that’s both equally educative and interesting, and let me tell you, you’ve hit the nail on the head. The problem is something which not enough people are speaking intelligently about. Now i’m very happy I found this during my hunt for something relating to this.

  2. 2020 年 8 月 1 日 17:06 | #2

    I like it when individuals come together and share ideas. Great blog, keep it up!

  3. 2020 年 8 月 1 日 17:18 | #3

    Your style is really unique compared to other folks I have read stuff from. Thanks for posting when you have the opportunity, Guess I’ll just bookmark this page.

  4. 2020 年 8 月 1 日 17:28 | #4

    I blog quite often and I really appreciate your content. This article has truly peaked my interest. I’m going to bookmark your blog and keep checking for new information about once per week. I opted in for your Feed as well.

  5. 2020 年 8 月 1 日 19:47 | #5

    Way cool! Some extremely valid points! I appreciate you writing this article plus the rest of the site is also very good.

  6. 2020 年 8 月 1 日 19:58 | #6

    Hi, I do believe this is an excellent website. I stumbledupon it ;) I am going to return yet again since I book-marked it. Money and freedom is the best way to change, may you be rich and continue to guide others.

  7. 2020 年 8 月 1 日 19:59 | #7

    Very good write-up. I definitely appreciate this website. Thanks!

  8. 2020 年 8 月 1 日 20:00 | #8

    That is a good tip particularly to those new to the blogosphere. Short but very accurate information… Thank you for sharing this one. A must read post!

  9. 2020 年 8 月 1 日 20:48 | #9

    generic viagra online [url=http://buyviagenonline.com/]generic viagra[/url] viagra online generic viagra generic viagra walmart

  10. 2020 年 8 月 1 日 21:05 | #10

    Having read this I believed it was very enlightening. I appreciate you taking the time and energy to put this informative article together. I once again find myself spending a lot of time both reading and leaving comments. But so what, it was still worthwhile!

  11. 2020 年 8 月 1 日 21:23 | #11

    Very good post! We will be linking to this particularly great article on our website. Keep up the good writing.

  12. 2020 年 8 月 1 日 21:53 | #12

    Spot on with this write-up, I actually believe that this web site needs a lot more attention. I’ll probably be returning to see more, thanks for the advice!

  13. 2020 年 8 月 1 日 23:25 | #13

    You need to be a part of a contest for one of the highest quality blogs online. I most certainly will highly recommend this site!

  14. 2020 年 8 月 1 日 23:38 | #14

    Good post. I learn something totally new and challenging on sites I stumbleupon every day. It will always be exciting to read articles from other writers and practice something from other websites.

  15. 2020 年 8 月 1 日 23:40 | #15

    May I just say what a comfort to discover an individual who genuinely knows what they’re talking about online. You certainly understand how to bring a problem to light and make it important. More and more people really need to look at this and understand this side of your story. I was surprised that you aren’t more popular since you surely have the gift.

  16. 2020 年 8 月 2 日 00:27 | #16

    Good post. I learn something totally new and challenging on websites I stumbleupon everyday. It’s always exciting to read through articles from other writers and practice a little something from other web sites.

  17. 2020 年 8 月 2 日 00:36 | #17

    This is the right blog for everyone who would like to understand this topic. You know a whole lot its almost tough to argue with you (not that I really will need to…HaHa). You certainly put a fresh spin on a topic that’s been discussed for a long time. Wonderful stuff, just wonderful!

  18. 2020 年 8 月 2 日 00:46 | #18

    Very good blog post. I definitely love this site. Stick with it!

  19. 2020 年 8 月 2 日 01:00 | #19

    You have made some really good points there. I checked on the net for more information about the issue and found most people will go along with your views on this website.

  20. 2020 年 8 月 2 日 02:06 | #20

    cialis generic [url=http://cialiisensf.com/]online cialis[/url] cialis online online cialis cialis 20mg

  21. 2020 年 8 月 2 日 02:34 | #21

    A fascinating discussion is worth comment. I believe that you ought to write more on this issue, it might not be a taboo subject but typically people do not discuss such topics. To the next! All the best!!

  22. 2020 年 8 月 2 日 02:34 | #22

    Good article! We are linking to this great article on our website. Keep up the great writing.

  23. 2020 年 8 月 2 日 03:23 | #23

    Hi there! This blog post could not be written any better! Looking at this article reminds me of my previous roommate! He continually kept preaching about this. I am going to send this post to him. Fairly certain he will have a great read. Thanks for sharing!

  24. 2020 年 8 月 2 日 03:32 | #24

    I need to to thank you for this good read!! I absolutely enjoyed every bit of it. I have you book-marked to check out new things you post…

  25. 2020 年 8 月 2 日 03:43 | #25

    After I originally commented I appear to have clicked the -Notify me when new comments are added- checkbox and from now on every time a comment is added I receive 4 emails with the exact same comment. Perhaps there is a way you can remove me from that service? Thanks a lot!

  26. 2020 年 8 月 2 日 03:58 | #26

    You made some decent points there. I looked on the web to find out more about the issue and found most people will go along with your views on this web site.

  27. 2020 年 8 月 2 日 09:02 | #27

    I simply desired to thank you so much all over again. I am not sure the things I would’ve gone through in the absence of those creative ideas shared by you about that situation. It has been a hard setting for me personally, but witnessing a new specialized fashion you resolved that made me to jump over delight. I will be happier for the information and as well , have high hopes you recognize what an amazing job your are carrying out training other individuals thru your web blog. I am sure you have never come across any of us.

  28. 2020 年 8 月 2 日 09:26 | #28

    generic bimatoprost ophthalmic solution https://www.jueriy.com/

  29. 2020 年 8 月 2 日 13:31 | #29

    Everything is very open with a very clear clarification of the challenges. It was definitely informative. Your site is very helpful. Many thanks for sharing!

  30. 2020 年 8 月 2 日 14:03 | #30

    bookmarked!!, I really like your web site!

  31. 2020 年 8 月 2 日 14:14 | #31

    A fascinating discussion is definitely worth comment. There’s no doubt that that you need to publish more about this topic, it may not be a taboo subject but usually people don’t speak about these topics. To the next! Best wishes!!

  32. 2020 年 8 月 2 日 14:16 | #32

    I enjoy reading through a post that can make people think. Also, thanks for allowing for me to comment!

  33. 2020 年 8 月 2 日 14:18 | #33

    viagra for sale [url=http://cheapvirgaraonline.com/]otc viagra[/url] viagra generic generic viagra generic viagra online

  34. 2020 年 8 月 2 日 14:56 | #34

    An impressive share! I’ve just forwarded this onto a coworker who was conducting a little research on this. And he actually bought me breakfast because I discovered it for him… lol. So allow me to reword this…. Thanks for the meal!! But yeah, thanks for spending some time to discuss this topic here on your website.

  35. 2020 年 8 月 2 日 15:22 | #35

    I’m extremely pleased to find this website. I need to to thank you for your time for this particularly wonderful read!! I definitely enjoyed every little bit of it and I have you book marked to look at new things in your website.

  36. 2020 年 8 月 2 日 15:28 | #36

    Good information. Lucky me I ran across your blog by accident (stumbleupon). I’ve bookmarked it for later!

  37. 2020 年 8 月 2 日 18:47 | #37

    You ought to take part in a contest for one of the greatest sites online. I am going to recommend this blog!

  38. 2020 年 8 月 2 日 19:08 | #38

    Everyone loves it when people get together and share ideas. Great blog, stick with it!

  39. 2020 年 8 月 2 日 19:21 | #39

    After going over a handful of the blog posts on your web page, I honestly like your technique of writing a blog. I added it to my bookmark site list and will be checking back soon. Please check out my website too and tell me your opinion.

  40. 2020 年 8 月 2 日 20:09 | #40

    Very good post. I absolutely appreciate this site. Keep it up!

  41. 2020 年 8 月 2 日 20:16 | #41

    Greetings! Very useful advice in this particular article! It’s the little changes which will make the biggest changes. Thanks a lot for sharing!

  42. 2020 年 8 月 2 日 20:26 | #42

    You are so cool! I do not believe I’ve read through anything like this before. So great to find someone with a few unique thoughts on this issue. Really.. thank you for starting this up. This website is one thing that is needed on the internet, someone with a little originality!

  43. 2020 年 8 月 2 日 20:42 | #43

    Greetings! Very helpful advice in this particular post! It is the little changes that make the largest changes. Many thanks for sharing!

  44. 2020 年 8 月 2 日 22:41 | #44

    I’m impressed, I have to admit. Rarely do I encounter a blog that’s equally educative and interesting, and without a doubt, you’ve hit the nail on the head. The issue is something which too few men and women are speaking intelligently about. I am very happy I came across this in my hunt for something relating to this.

  45. 2020 年 8 月 2 日 23:13 | #45

    Greetings! Very useful advice within this post! It’s the little changes that make the most important changes. Thanks a lot for sharing!

  46. 2020 年 8 月 2 日 23:15 | #46

    Hi there! I just wish to give you a big thumbs up for the excellent information you have right here on this post. I will be coming back to your web site for more soon.

  47. 2020 年 8 月 3 日 00:04 | #47

    Hello there! This blog post could not be written any better! Looking through this article reminds me of my previous roommate! He continually kept preaching about this. I most certainly will send this post to him. Fairly certain he will have a very good read. Thank you for sharing!

  48. 2020 年 8 月 3 日 00:11 | #48

    Howdy! I just wish to give you a huge thumbs up for the great information you have here on this post. I will be coming back to your web site for more soon.

  49. 2020 年 8 月 3 日 00:21 | #49

    I used to be able to find good information from your blog articles.

  50. 2020 年 8 月 3 日 00:37 | #50

    When I initially left a comment I seem to have clicked on the -Notify me when new comments are added- checkbox and now whenever a comment is added I recieve four emails with the exact same comment. Is there an easy method you are able to remove me from that service? Thanks!

コメントページ
1 128 129 130 131 132 202 344
  1. 2020 年 4 月 14 日 19:42 | #1
  2. 2020 年 4 月 20 日 11:24 | #2
  3. 2020 年 4 月 26 日 04:06 | #3
  4. 2020 年 4 月 26 日 09:54 | #4
  5. 2020 年 4 月 30 日 00:35 | #5
  6. 2020 年 5 月 5 日 14:56 | #6
  7. 2020 年 5 月 5 日 19:12 | #7
  8. 2020 年 5 月 10 日 00:44 | #8
  9. 2020 年 6 月 30 日 00:36 | #9
  10. 2020 年 7 月 11 日 18:18 | #10
  11. 2020 年 7 月 19 日 08:12 | #11
  12. 2020 年 7 月 23 日 13:36 | #12
  13. 2020 年 7 月 24 日 15:13 | #13
  14. 2020 年 7 月 26 日 19:30 | #14
  15. 2020 年 7 月 30 日 02:39 | #15
  16. 2020 年 7 月 30 日 09:32 | #16
  17. 2020 年 8 月 5 日 02:49 | #17
  18. 2020 年 8 月 6 日 17:10 | #18
  19. 2020 年 8 月 6 日 20:26 | #19
  20. 2020 年 8 月 6 日 22:52 | #20
  21. 2020 年 8 月 7 日 06:34 | #21
  22. 2020 年 8 月 8 日 18:57 | #22
  23. 2020 年 8 月 9 日 18:49 | #23
  24. 2020 年 8 月 9 日 23:00 | #24
  25. 2020 年 8 月 9 日 23:41 | #25
  26. 2020 年 8 月 10 日 00:54 | #26
  27. 2020 年 8 月 10 日 00:58 | #27
  28. 2020 年 8 月 10 日 04:59 | #28
  29. 2020 年 8 月 10 日 05:28 | #29
  30. 2020 年 8 月 10 日 06:33 | #30
  31. 2020 年 8 月 10 日 08:31 | #31
  32. 2020 年 8 月 10 日 10:10 | #32
  33. 2020 年 8 月 10 日 11:39 | #33
  34. 2020 年 8 月 10 日 11:51 | #34
  35. 2020 年 8 月 10 日 14:46 | #35
  36. 2020 年 8 月 10 日 16:38 | #36
  37. 2020 年 8 月 10 日 21:58 | #37
  38. 2020 年 8 月 11 日 01:52 | #38
  39. 2020 年 8 月 11 日 02:56 | #39
  40. 2020 年 8 月 11 日 04:06 | #40
  41. 2020 年 8 月 11 日 06:30 | #41
  42. 2020 年 8 月 11 日 07:58 | #42
  43. 2020 年 8 月 11 日 08:39 | #43
  44. 2020 年 8 月 11 日 10:45 | #44
  45. 2020 年 8 月 11 日 12:32 | #45
  46. 2020 年 8 月 11 日 16:00 | #46
  47. 2020 年 8 月 11 日 16:08 | #47
  48. 2020 年 8 月 11 日 17:49 | #48
  49. 2020 年 8 月 11 日 19:07 | #49
  50. 2020 年 8 月 11 日 20:38 | #50
  51. 2020 年 8 月 11 日 21:47 | #51
  52. 2020 年 8 月 11 日 23:00 | #52
  53. 2020 年 8 月 12 日 00:35 | #53
  54. 2020 年 8 月 12 日 04:22 | #54
  55. 2020 年 8 月 12 日 05:47 | #55
  56. 2020 年 8 月 12 日 07:27 | #56
  57. 2020 年 8 月 12 日 09:21 | #57
  58. 2020 年 8 月 12 日 11:38 | #58
  59. 2020 年 8 月 12 日 12:38 | #59
  60. 2020 年 8 月 12 日 17:43 | #60
  61. 2020 年 8 月 12 日 18:31 | #61
  62. 2020 年 8 月 12 日 19:15 | #62
  63. 2020 年 8 月 12 日 21:59 | #63
  64. 2020 年 8 月 12 日 23:26 | #64
  65. 2020 年 8 月 12 日 23:57 | #65
  66. 2020 年 8 月 13 日 01:55 | #66
  67. 2020 年 8 月 13 日 02:34 | #67
  68. 2020 年 8 月 13 日 04:35 | #68
  69. 2020 年 8 月 13 日 07:31 | #69
  70. 2020 年 8 月 13 日 09:19 | #70
  71. 2020 年 8 月 13 日 10:54 | #71
  72. 2020 年 8 月 13 日 14:16 | #72
  73. 2020 年 8 月 13 日 15:03 | #73
  74. 2020 年 8 月 13 日 16:43 | #74
  75. 2020 年 8 月 13 日 17:00 | #75
  76. 2020 年 8 月 13 日 19:12 | #76
  77. 2020 年 8 月 13 日 20:30 | #77
  78. 2020 年 8 月 14 日 01:49 | #78
  79. 2020 年 8 月 14 日 04:08 | #79
  80. 2020 年 8 月 14 日 07:18 | #80
  81. 2020 年 8 月 14 日 08:03 | #81
  82. 2020 年 8 月 14 日 09:28 | #82
  83. 2020 年 8 月 14 日 10:01 | #83
  84. 2020 年 8 月 14 日 13:19 | #84
  85. 2020 年 8 月 14 日 17:46 | #85
  86. 2020 年 8 月 14 日 19:50 | #86
  87. 2020 年 8 月 14 日 21:15 | #87
  88. 2020 年 8 月 15 日 00:16 | #88
  89. 2020 年 8 月 15 日 16:15 | #89
  90. 2020 年 8 月 16 日 17:04 | #90
  91. 2020 年 8 月 17 日 16:51 | #91
  92. 2020 年 8 月 17 日 18:32 | #92
  93. 2020 年 8 月 19 日 17:43 | #93
  94. 2020 年 8 月 20 日 17:08 | #94
  95. 2020 年 8 月 22 日 20:46 | #95
  96. 2020 年 8 月 24 日 14:35 | #96
  97. 2020 年 8 月 25 日 06:50 | #97
  98. 2020 年 8 月 25 日 17:22 | #98
  99. 2020 年 8 月 26 日 17:07 | #99
  100. 2020 年 8 月 26 日 17:21 | #100
  101. 2020 年 8 月 26 日 18:47 | #101
  102. 2020 年 8 月 26 日 19:12 | #102
  103. 2020 年 8 月 26 日 21:33 | #103
  104. 2020 年 8 月 27 日 07:46 | #104
  105. 2020 年 8 月 28 日 07:07 | #105
  106. 2020 年 8 月 29 日 17:44 | #106
  107. 2020 年 8 月 30 日 19:59 | #107
  108. 2020 年 8 月 31 日 05:48 | #108
  109. 2020 年 8 月 31 日 06:37 | #109
  110. 2020 年 8 月 31 日 17:09 | #110
  111. 2020 年 9 月 1 日 23:09 | #111
  112. 2020 年 9 月 2 日 01:22 | #112
  113. 2020 年 9 月 2 日 01:42 | #113
  114. 2020 年 9 月 2 日 04:47 | #114
  115. 2020 年 9 月 2 日 06:22 | #115
  116. 2020 年 9 月 2 日 07:15 | #116
  117. 2020 年 9 月 2 日 15:52 | #117
  118. 2020 年 9 月 2 日 17:37 | #118
  119. 2020 年 9 月 3 日 07:05 | #119
  120. 2020 年 9 月 4 日 04:36 | #120
  121. 2020 年 9 月 6 日 16:58 | #121
  122. 2020 年 9 月 8 日 06:41 | #122
  123. 2020 年 9 月 13 日 07:14 | #123
  124. 2020 年 9 月 13 日 18:43 | #124
  125. 2020 年 9 月 14 日 19:29 | #125
  126. 2020 年 9 月 16 日 07:02 | #126
  127. 2020 年 9 月 17 日 16:14 | #127
  128. 2020 年 9 月 17 日 16:27 | #128
  129. 2020 年 9 月 17 日 20:57 | #129
  130. 2020 年 9 月 18 日 05:48 | #130