Patchwork [05/26] lib: fwts_framework: remove redundant parameter from fwts_framework_run_test

login
register
mail settings
Submitter Colin King
Date Oct. 14, 2012, 8:31 p.m.
Message ID <1350246738-31699-6-git-send-email-colin.king@canonical.com>
Download mbox | patch
Permalink /patch/191396/
State Accepted
Headers show

Comments

Colin King - Oct. 14, 2012, 8:31 p.m.
From: Colin Ian King <colin.king@canonical.com>

Remove redundant parameter num_tests from fwts_framework_run_test, it is
no longer required, legacy cruft.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 src/lib/src/fwts_framework.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Alex Hung - Oct. 15, 2012, 3:06 a.m.
On 10/15/2012 04:31 AM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Remove redundant parameter num_tests from fwts_framework_run_test, it is
> no longer required, legacy cruft.
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
>   src/lib/src/fwts_framework.c |    4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/lib/src/fwts_framework.c b/src/lib/src/fwts_framework.c
> index aa26d4b..3be2c3e 100644
> --- a/src/lib/src/fwts_framework.c
> +++ b/src/lib/src/fwts_framework.c
> @@ -464,7 +464,7 @@ static int fwts_framework_total_summary(fwts_framework *fw)
>   	return FWTS_OK;
>   }
>
> -static int fwts_framework_run_test(fwts_framework *fw, const int num_tests, fwts_framework_test *test)
> +static int fwts_framework_run_test(fwts_framework *fw, fwts_framework_test *test)
>   {
>   	fwts_framework_minor_test *minor_test;
>   	int ret;
> @@ -627,7 +627,7 @@ static void fwts_framework_tests_run(fwts_framework *fw, fwts_list *tests_to_run
>
>   	fwts_list_foreach(item, tests_to_run) {
>   		fwts_framework_test *test = fwts_list_data(fwts_framework_test *, item);
> -		fwts_framework_run_test(fw, fwts_list_len(tests_to_run), test);
> +		fwts_framework_run_test(fw, test);
>   		fw->current_major_test_num++;
>   	}
>   }
>
Acked-by: Alex Hung <alex.hung@canonical.com>
Keng-Yu Lin - Oct. 17, 2012, 7:38 a.m.
On Mon, Oct 15, 2012 at 4:31 AM, Colin King <colin.king@canonical.com> wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Remove redundant parameter num_tests from fwts_framework_run_test, it is
> no longer required, legacy cruft.
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
>  src/lib/src/fwts_framework.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/lib/src/fwts_framework.c b/src/lib/src/fwts_framework.c
> index aa26d4b..3be2c3e 100644
> --- a/src/lib/src/fwts_framework.c
> +++ b/src/lib/src/fwts_framework.c
> @@ -464,7 +464,7 @@ static int fwts_framework_total_summary(fwts_framework *fw)
>         return FWTS_OK;
>  }
>
> -static int fwts_framework_run_test(fwts_framework *fw, const int num_tests, fwts_framework_test *test)
> +static int fwts_framework_run_test(fwts_framework *fw, fwts_framework_test *test)
>  {
>         fwts_framework_minor_test *minor_test;
>         int ret;
> @@ -627,7 +627,7 @@ static void fwts_framework_tests_run(fwts_framework *fw, fwts_list *tests_to_run
>
>         fwts_list_foreach(item, tests_to_run) {
>                 fwts_framework_test *test = fwts_list_data(fwts_framework_test *, item);
> -               fwts_framework_run_test(fw, fwts_list_len(tests_to_run), test);
> +               fwts_framework_run_test(fw, test);
>                 fw->current_major_test_num++;
>         }
>  }
> --
> 1.7.10.4
>
Acked-by: Keng-Yu Lin <kengyu@canonical.com>

Patch

diff --git a/src/lib/src/fwts_framework.c b/src/lib/src/fwts_framework.c
index aa26d4b..3be2c3e 100644
--- a/src/lib/src/fwts_framework.c
+++ b/src/lib/src/fwts_framework.c
@@ -464,7 +464,7 @@  static int fwts_framework_total_summary(fwts_framework *fw)
 	return FWTS_OK;
 }
 
-static int fwts_framework_run_test(fwts_framework *fw, const int num_tests, fwts_framework_test *test)
+static int fwts_framework_run_test(fwts_framework *fw, fwts_framework_test *test)
 {
 	fwts_framework_minor_test *minor_test;
 	int ret;
@@ -627,7 +627,7 @@  static void fwts_framework_tests_run(fwts_framework *fw, fwts_list *tests_to_run
 
 	fwts_list_foreach(item, tests_to_run) {
 		fwts_framework_test *test = fwts_list_data(fwts_framework_test *, item);
-		fwts_framework_run_test(fw, fwts_list_len(tests_to_run), test);
+		fwts_framework_run_test(fw, test);
 		fw->current_major_test_num++;
 	}
 }