This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Given /^an IO stream containing ([0-9a-fA-F]+)$/ do |hex_bytes| | |
@io = StringIO.new([hex_bytes].pack('H*')) | |
end | |
When /^I deserialize the stream$/ do | |
@document = Hash.from_bson(@io) | |
end | |
Then /^the result should be the ((?:\S+) value (?:\S+))$/ do |value| | |
@document['k'].should eq(value) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Given /^an IO stream containing ([0-9a-fA-F]+)$/ do |hex_bytes| | |
@io = StringIO.new([hex_bytes].pack('H*')) | |
end | |
When /^I deserialize the stream$/ do | |
@document = Hash.from_bson(@io) | |
end | |
Then /^the result should be the ((?:\S+) value (?:\S+))$/ do |value| | |
@document['k'].should eq(value) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@bson | |
Feature: Deserialize Elements | |
As a user of MongoDB | |
In order to retrieve data from the database | |
The driver needs to deserialize BSON elements | |
Scenario Outline: Deserialize singleton BSON objects | |
Given an IO stream containing <hex_bytes> | |
When I deserialize the stream | |
Then the result should be the <type> value <value> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: Addition | |
As someone who works with numbers | |
I want to be able to learn the total of my numbers | |
So I add my numbers together to get a result | |
Scenario: Adding two numbers # features/adding.feature:6 | |
Given the number 5 # features/step_definitions/step_definitions.rb:1 | |
And the other number 42 # features/step_definitions/step_definitions.rb:5 | |
When I add the two numbers # features/step_definitions/step_definitions.rb:9 | |
Then the result should be 47 # features/step_definitions/step_definitions.rb:13 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Given /^the number (-?\d+)$/ do |addend| | |
@addend1 = addend.to_i | |
end | |
Given /^the other number (-?\d+)$/ do |addend| | |
@addend2 = addend.to_i | |
end | |
When /^I add the two numbers$/ do | |
@sum = @addend1 + @addend2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: Addition | |
As someone who works with numbers | |
I want to be able to learn the total of my numbers | |
So I add my numbers together to get a result | |
Scenario: Adding two numbers | |
Given the number 5 | |
And the other number 42 | |
When I add the two numbers | |
Then the result should be 47 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND | |
28564 dwight 20 0 1292m 1.0g 1.0g S 609.1 3.3 0:47.11 mongoperf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parsed options: | |
{ nThreads: 32, fileSizeMB: 1000, r: true, mmf: true } | |
creating test file size:1000MB ... | |
testing... | |
new thread, total running : 1 | |
67 ops/sec | |
110 ops/sec | |
184 ops/sec | |
167 ops/sec | |
174 ops/sec |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Device: rrqm/s wrqm/s r/s w/s rMB/s wMB/s avgrq-sz avgqu-sz await svctm %util | |
sdc 148.33 0.00 116.00 0.00 22.30 0.00 393.63 1.68 14.48 7.19 83.40 | |
sdd 130.67 0.00 113.00 0.00 20.38 0.00 369.35 1.54 13.58 7.19 81.23 | |
sde 154.00 0.00 113.67 0.00 21.85 0.00 393.64 1.84 16.23 7.38 83.87 | |
sdb 140.00 0.00 107.00 0.00 20.27 0.00 387.91 1.88 17.58 7.84 83.87 | |
md0 0.00 0.00 1025.33 0.00 85.34 0.00 170.45 0.00 0.00 0.00 0.00 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parsed options: | |
{ recSizeKB: 8, nThreads: 8, fileSizeMB: 1000, r: true, mmf: true } | |
creating test file size:1000MB ... | |
new thread, total running : 1 | |
read:1 write:0 | |
65 ops/sec | |
79 ops/sec | |
92 ops/sec | |
107 ops/sec | |
111 ops/sec |