From a96d2dfb135f93a74f070d1c27374351f5b064a4 Mon Sep 17 00:00:00 2001 From: Feng Pan Date: Sat, 16 Sep 2017 23:03:24 -0400 Subject: Add capability to configure socket-mem JIRA: PUP-5 Change-Id: I6fef4c129356d7a2d8b6d4975aada9abdeb68758 Signed-off-by: Feng Pan --- spec/acceptance/fdio_spec.rb | 3 ++- spec/classes/fdio_spec.rb | 13 +++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) (limited to 'spec') diff --git a/spec/acceptance/fdio_spec.rb b/spec/acceptance/fdio_spec.rb index a3a0a17..18e54b0 100644 --- a/spec/acceptance/fdio_spec.rb +++ b/spec/acceptance/fdio_spec.rb @@ -7,7 +7,7 @@ describe 'fdio' do it 'should work with no errors' do pp= <<-EOS class { '::fdio': - repo_branch => 'stable.1704' + repo_branch => 'stable.1707' } EOS @@ -35,6 +35,7 @@ describe 'fdio' do it 'should work with no errors' do pp= <<-EOS class { '::fdio': + repo_branch => 'stable.1707', vpp_cpu_main_core => '1', vpp_cpu_corelist_workers => '2', } diff --git a/spec/classes/fdio_spec.rb b/spec/classes/fdio_spec.rb index 847bc08..8f0a088 100644 --- a/spec/classes/fdio_spec.rb +++ b/spec/classes/fdio_spec.rb @@ -2,6 +2,10 @@ require 'spec_helper' describe 'fdio' do + let :params do + {} + end + shared_examples_for 'fdio - default' do it { should compile } it { should compile.with_all_deps } @@ -58,6 +62,15 @@ describe 'fdio' do 'unless' => 'lsmod | grep uio_pci_generic', ) } + + context 'with socket_mem' do + before :each do + params.merge!(:vpp_dpdk_socket_mem => '1024,1024') + end + it 'should configure socket_mem' do + is_expected.to contain_vpp_config('dpdk/socket-mem').with_value('1024,1024') + end + end end shared_examples_for 'fdio - service' do -- cgit 1.2.3-korg