Results for “Testing & reusable patterns”
Small, practical examples. Search by task or narrow things down below.
Create a runtime file during the build
Docker / Compose: RUN executes during the build while CMD executes when a container starts.
Docker / Compose✓ Tested
Exclude files from the build context
Docker / Compose: A dockerignore file prevents selected local files from being copied.
Docker / Compose✓ Tested
Keep exec-form arguments literal
Docker / Compose: JSON exec form does not expand shell environment variables.
Docker / Compose✓ Tested
Prepare an owned directory before dropping root
Docker / Compose: Create and chown the writable application path before USER.
Docker / Compose✓ Tested
Set copied files’ numeric ownership
Docker / Compose: COPY --chown sets ownership while adding the file.
Docker / Compose✓ Tested
Use a build argument while creating an image
Docker / Compose: ARG supplies a build-time value that is not automatically a runtime environment variable.
Docker / Compose✓ Tested
Allow pointer input to pass through a decorative overlay
CSS: Pointer-events none excludes the overlay from ordinary pointer hit testing.
CSS✓ Tested
Define a one-off Compose service
Describe an image and command in a reusable YAML file.
Compose✓ Tested
Describe an object with an interface
Require named fields on a reusable object shape.
interface✓ Tested
Dispatch a command with case
Choose an action from a small set of supported commands.
case✓ Tested
Find parents with at least two child rows
SQL: Use a correlated count when testing a per-parent threshold.
SQL✓ Tested
Find parents with at least two child rows
SQL Server: Use a correlated count when testing a per-parent threshold.
SQL Server✓ Tested