apache / apache/beam

Integration tests should create/destroy resources required for running

Open
#18,077 0 comments 0 reactions 0 assignees View on GitHub
bug P3 tests
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
1d 20h
Merged PRs (30d)
196

Description

By not creating/tearing down resources in integration tests, the tests are not portable or easily runnable by a user who doesn't have access to all the pre-created test artifacts.

For example BigtableReadIT assumes that it is executing in a project which has a specifically named Bigtable instance preloaded with testdata.

Also, KinesisReaderIT assumes an already created Kinesis topic exists.

Imported from Jira [BEAM-686](https://issues.apache.org/jira/browse/BEAM-686). Original Jira may contain additional context.
Reported by: lcwik.

Contributor guide

Open the contributing guide

Research direction

Start by inspecting the BigtableReadIT and KinesisReaderIT integration tests, focusing on their assumptions about pre-created test artifacts. Identify how each test currently depends on existing resources and determine the setup and teardown needed. Done means the tests create and destroy their required resources and no longer require those pre-created artifacts.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
testing
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.