Skip to content

Commit

Permalink
add csv data set example
Browse files Browse the repository at this point in the history
  • Loading branch information
timkoopmans committed Aug 15, 2017
1 parent 6ff1f14 commit a173aeb
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ tmp
*.jtl
*.bak
.byebug_history
.DS_Store
19 changes: 19 additions & 0 deletions examples/csv_data_set.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
require 'ruby-jmeter'

test do
csv_data_set_config filename: 'postcodes.csv',
variableNames: 'postcode'

threads count: 1 do
visit name: 'Home', url: 'https://flooded.io?query=${postcode}'
end
end.flood ENV['FLOOD_API_TOKEN'],
privacy: 'public',
name: ENV['FLOOD_NAME'] ||= 'Simple Demo',
project: 'workspace',
region: ENV['REGION'] ||= 'us-west-2',
override_parameters: '-Dsun.net.inetaddr.ttl=30',
files: [
"#{Dir.pwd}/postcodes.csv"
]

0 comments on commit a173aeb

Please sign in to comment.