apache / streampipes

Apache StreamPipes - A self-service (Industrial) IoT toolbox to enable non-technical users to connect, analyze and explore IoT data streams.
https://streampipes.apache.org
Apache License 2.0
545 stars 168 forks source link

Unit testing framework updates #2737

Closed IsaakKrut closed 2 days ago

IsaakKrut commented 2 weeks ago

Body

Related to #2374

As discussed in PR #2730

StreamPipes Committer

I acknowledge that I am a maintainer/committer of the Apache StreamPipes project.

IsaakKrut commented 1 week ago

Hi @tenthe,

I pushed my changes to the branch apache:2374-provide-a-framework-to-easily-unit-test-processing-elements. I am having issues with moving the code to a different module. When I tried moving it to streampipes-test-utils I had errors with cyclic dependencies. I created a new module streampipes-test-utils-executors, but getting this error: The following artifacts could not be resolved: org.apache.streampipes:streampipes-test-utils-executors:jar:tests:0.95.0-SNAPSHOT (absent): org.apache.streampipes:streampipes-test-utils-executors:jar:tests:0.95.0-SNAPSHOT was not found in https://repository.apache.org/snapshots

How should I proceed with that?

Regarding the functionality you can see commit https://github.com/apache/streampipes/commit/c25b1bee61ce3a5dc366344024f00056ec957e8a

All tests are working. I have identified 4 scenarios for the selector prefix:

  1. Default. By default the prefix will be an empty string
  2. SAME_PREFIX. Will use s0 for all events
  3. ALTERNATE. Will alternate between s0 and s1
  4. Custom. Accepts a list of prefixes that will be iterated over during event generation.

I assume after the issue with maven modules is fixed I can create a PR from 2374-provide-a-framework-to-easily-unit-test-processing-elements to the dev branch

tenthe commented 1 week ago

Hi @IsaakKrut,

thank you for the changes. I will have a look at them, but will take until next week.

Cheers, Philipp

bossenti commented 2 days ago

Closed by https://github.com/apache/streampipes/pull/2375