- changed 'parameter' to 'argument' in text because it's more accurate.

git-svn-id: http://cmock.svn.sourceforge.net/svnroot/cmock/trunk@92 bf332499-1b4d-0410-844d-d2d48d5cc64c
This commit is contained in:
mvandervoord
2009-05-13 23:15:01 +00:00
parent 49d8d32ef5
commit 71729e1b65
3 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -26,7 +26,7 @@ class CMockConfig
when NilClass then options = CMockDefaultOptions.clone
when String then options = CMockDefaultOptions.clone.merge(load_config_file_from_yaml(options))
when Hash then options = CMockDefaultOptions.clone.merge(options)
else raise "If you specify parameters, it should be a filename or a hash of options"
else raise "If you specify arguments, it should be a filename or a hash of options"
end
@options = options
@options.each_key { |key| eval("def #{key}() return @options[:#{key}] end") }
+1 -1
View File
@@ -72,7 +72,7 @@ class CMockGeneratorUtils
"#{@tab}{\n",
"#{@tab}#{@tab}#{arg_type}* p_expected = Mock.#{function[:name]}_Expected_#{actual};\n",
"#{@tab}#{@tab}Mock.#{function[:name]}_Expected_#{actual}++;\n",
expect_helper(arg_type, '*p_expected', actual, "\"Function '#{function[:name]}' called with unexpected value for parameter '#{actual}'.\"","#{@tab}#{@tab}"),
expect_helper(arg_type, '*p_expected', actual, "\"Function '#{function[:name]}' called with unexpected value for argument '#{actual}'.\"","#{@tab}#{@tab}"),
"#{@tab}}\n" ].flatten
end
+5 -5
View File
@@ -184,7 +184,7 @@ class CMockGeneratorUtilsTest < Test::Unit::TestCase
" {\n",
" uint16* p_expected = Mock.CanOpener_Expected_CorkScrew;\n",
" Mock.CanOpener_Expected_CorkScrew++;\n",
" TEST_ASSERT_EQUAL_MESSAGE(*p_expected, CorkScrew, \"Function 'CanOpener' called with unexpected value for parameter 'CorkScrew'.\");\n",
" TEST_ASSERT_EQUAL_MESSAGE(*p_expected, CorkScrew, \"Function 'CanOpener' called with unexpected value for argument 'CorkScrew'.\");\n",
" }\n"
]
returned = @cmock_generator_utils.code_verify_an_arg_expectation(function, var_type, var_name)
@@ -204,7 +204,7 @@ class CMockGeneratorUtilsTest < Test::Unit::TestCase
" {\n",
" const char** p_expected = Mock.MeasureCup_Expected_TeaSpoon;\n",
" Mock.MeasureCup_Expected_TeaSpoon++;\n",
" TEST_ASSERT_EQUAL_STRING_MESSAGE(*p_expected, TeaSpoon, \"Function 'MeasureCup' called with unexpected value for parameter 'TeaSpoon'.\");\n",
" TEST_ASSERT_EQUAL_STRING_MESSAGE(*p_expected, TeaSpoon, \"Function 'MeasureCup' called with unexpected value for argument 'TeaSpoon'.\");\n",
" }\n"
]
returned = @cmock_generator_utils.code_verify_an_arg_expectation(function, var_type, var_name)
@@ -224,7 +224,7 @@ class CMockGeneratorUtilsTest < Test::Unit::TestCase
" {\n",
" MANDELBROT_SET_T* p_expected = Mock.TeaPot_Expected_TeaSpoon;\n",
" Mock.TeaPot_Expected_TeaSpoon++;\n",
" TEST_ASSERT_EQUAL_MANDELBROT_SET_T_MESSAGE(*p_expected, TeaSpoon, \"Function 'TeaPot' called with unexpected value for parameter 'TeaSpoon'.\");\n",
" TEST_ASSERT_EQUAL_MANDELBROT_SET_T_MESSAGE(*p_expected, TeaSpoon, \"Function 'TeaPot' called with unexpected value for argument 'TeaSpoon'.\");\n",
" }\n"
]
returned = @cmock_generator_utils.code_verify_an_arg_expectation(function, var_type, var_name)
@@ -244,7 +244,7 @@ class CMockGeneratorUtilsTest < Test::Unit::TestCase
" {\n",
" SOME_STRUCT* p_expected = Mock.Toaster_Expected_Bread;\n",
" Mock.Toaster_Expected_Bread++;\n",
" TEST_ASSERT_EQUAL_MEMORY_MESSAGE((void*)p_expected, (void*)&(Bread), sizeof(SOME_STRUCT), \"Function 'Toaster' called with unexpected value for parameter 'Bread'.\");\n",
" TEST_ASSERT_EQUAL_MEMORY_MESSAGE((void*)p_expected, (void*)&(Bread), sizeof(SOME_STRUCT), \"Function 'Toaster' called with unexpected value for argument 'Bread'.\");\n",
" }\n"
]
returned = @cmock_generator_utils.code_verify_an_arg_expectation(function, var_type, var_name)
@@ -267,7 +267,7 @@ class CMockGeneratorUtilsTest < Test::Unit::TestCase
" if (*p_expected == NULL)\n",
" { TEST_ASSERT_NULL(Strawberry); }\n",
" else\n",
" { TEST_ASSERT_EQUAL_FRUIT_ARRAY_MESSAGE(*p_expected, Strawberry, 1, \"Function 'Blender' called with unexpected value for parameter 'Strawberry'.\"); }\n",
" { TEST_ASSERT_EQUAL_FRUIT_ARRAY_MESSAGE(*p_expected, Strawberry, 1, \"Function 'Blender' called with unexpected value for argument 'Strawberry'.\"); }\n",
" }\n"
]
returned = @cmock_generator_utils.code_verify_an_arg_expectation(function, var_type, var_name)