[libcamera-devel,7/8] libcamera: test: remove test IPA and use dummy IPA instead

Message ID 20190527223540.21855-8-paul.elder@ideasonboard.com
State Superseded
Headers show
Series
  • Add IPAManager and IPAInterface
Related show

Commit Message

Paul Elder May 27, 2019, 10:35 p.m. UTC
Use the dummy IPA for testing/sample IPA instead of the earlier test
IPA. Remove the test IPA, and update tests and meson accordingly.

Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
---
 test/ipa/ipa_test.cpp |  8 ++++----
 test/ipa/meson.build  | 10 ----------
 2 files changed, 4 insertions(+), 14 deletions(-)

Comments

Laurent Pinchart May 28, 2019, 4:25 p.m. UTC | #1
Hi Paul,

Thank you for the patch.

On Mon, May 27, 2019 at 06:35:39PM -0400, Paul Elder wrote:
> Use the dummy IPA for testing/sample IPA instead of the earlier test
> IPA. Remove the test IPA, and update tests and meson accordingly.

Nice, I like this. Please disregard my comment about using more
realistic names for the test module info in an earlier patch.

> Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
> ---
>  test/ipa/ipa_test.cpp |  8 ++++----
>  test/ipa/meson.build  | 10 ----------
>  2 files changed, 4 insertions(+), 14 deletions(-)
> 
> diff --git a/test/ipa/ipa_test.cpp b/test/ipa/ipa_test.cpp
> index f50880e..53e3a6e 100644
> --- a/test/ipa/ipa_test.cpp
> +++ b/test/ipa/ipa_test.cpp
> @@ -82,12 +82,12 @@ protected:
>  
>  		const struct IPAModuleInfo testInfo = {
>  			1,
> -			0, 9001,
> -			"bleep",
> -			"It's over nine thousand!",
> +			0, 1,
> +			"PipelineHandlerVimc",
> +			"Dummy IPA for Vimc",
>  		};
>  
> -		count += runTest("test/ipa/ipa-dummy-cpp.so", testInfo);
> +		count += runTest("src/ipa/ipa_dummy.so", testInfo);
>  
>  		if (count < 0)
>  			return TestFail;
> diff --git a/test/ipa/meson.build b/test/ipa/meson.build
> index 08ee95c..bca39fa 100644
> --- a/test/ipa/meson.build
> +++ b/test/ipa/meson.build
> @@ -1,13 +1,3 @@
> -ipa_modules_sources = [
> -    ['ipa-dummy-cpp', 'shared_test.cpp'],
> -]
> -
> -foreach m : ipa_modules_sources
> -    shared_library(m, name_prefix : '',
> -                   dependencies : libcamera_dep,
> -                   include_directories : test_includes_public)
> -endforeach
> -
>  ipa_test = [
>      ['ipa_test', 'ipa_test.cpp'],
>  ]
Laurent Pinchart May 28, 2019, 4:26 p.m. UTC | #2
On Tue, May 28, 2019 at 07:25:26PM +0300, Laurent Pinchart wrote:
> Hi Paul,
> 
> Thank you for the patch.
> 
> On Mon, May 27, 2019 at 06:35:39PM -0400, Paul Elder wrote:
> > Use the dummy IPA for testing/sample IPA instead of the earlier test
> > IPA. Remove the test IPA, and update tests and meson accordingly.
> 
> Nice, I like this. Please disregard my comment about using more
> realistic names for the test module info in an earlier patch.

And

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> > Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
> > ---
> >  test/ipa/ipa_test.cpp |  8 ++++----
> >  test/ipa/meson.build  | 10 ----------
> >  2 files changed, 4 insertions(+), 14 deletions(-)
> > 
> > diff --git a/test/ipa/ipa_test.cpp b/test/ipa/ipa_test.cpp
> > index f50880e..53e3a6e 100644
> > --- a/test/ipa/ipa_test.cpp
> > +++ b/test/ipa/ipa_test.cpp
> > @@ -82,12 +82,12 @@ protected:
> >  
> >  		const struct IPAModuleInfo testInfo = {
> >  			1,
> > -			0, 9001,
> > -			"bleep",
> > -			"It's over nine thousand!",
> > +			0, 1,
> > +			"PipelineHandlerVimc",
> > +			"Dummy IPA for Vimc",
> >  		};
> >  
> > -		count += runTest("test/ipa/ipa-dummy-cpp.so", testInfo);
> > +		count += runTest("src/ipa/ipa_dummy.so", testInfo);
> >  
> >  		if (count < 0)
> >  			return TestFail;
> > diff --git a/test/ipa/meson.build b/test/ipa/meson.build
> > index 08ee95c..bca39fa 100644
> > --- a/test/ipa/meson.build
> > +++ b/test/ipa/meson.build
> > @@ -1,13 +1,3 @@
> > -ipa_modules_sources = [
> > -    ['ipa-dummy-cpp', 'shared_test.cpp'],
> > -]
> > -
> > -foreach m : ipa_modules_sources
> > -    shared_library(m, name_prefix : '',
> > -                   dependencies : libcamera_dep,
> > -                   include_directories : test_includes_public)
> > -endforeach
> > -
> >  ipa_test = [
> >      ['ipa_test', 'ipa_test.cpp'],
> >  ]

Patch

diff --git a/test/ipa/ipa_test.cpp b/test/ipa/ipa_test.cpp
index f50880e..53e3a6e 100644
--- a/test/ipa/ipa_test.cpp
+++ b/test/ipa/ipa_test.cpp
@@ -82,12 +82,12 @@  protected:
 
 		const struct IPAModuleInfo testInfo = {
 			1,
-			0, 9001,
-			"bleep",
-			"It's over nine thousand!",
+			0, 1,
+			"PipelineHandlerVimc",
+			"Dummy IPA for Vimc",
 		};
 
-		count += runTest("test/ipa/ipa-dummy-cpp.so", testInfo);
+		count += runTest("src/ipa/ipa_dummy.so", testInfo);
 
 		if (count < 0)
 			return TestFail;
diff --git a/test/ipa/meson.build b/test/ipa/meson.build
index 08ee95c..bca39fa 100644
--- a/test/ipa/meson.build
+++ b/test/ipa/meson.build
@@ -1,13 +1,3 @@ 
-ipa_modules_sources = [
-    ['ipa-dummy-cpp', 'shared_test.cpp'],
-]
-
-foreach m : ipa_modules_sources
-    shared_library(m, name_prefix : '',
-                   dependencies : libcamera_dep,
-                   include_directories : test_includes_public)
-endforeach
-
 ipa_test = [
     ['ipa_test', 'ipa_test.cpp'],
 ]