[Bug]: `ImageNameSubstitutor` cannot set compatibility

Đang mở
#9,575 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
48/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
docker, java
Lĩnh vực
testing

Hướng nghiên cứu

Bắt đầu với lớp ImageNameSubstitutor và kiểm tra các phần triển khai của nó, sau đó lần theo nơi thuộc tính image cha và assertion về tính tương thích được sử dụng. Thêm một regression test bao quát một substitutor tùy chỉnh đánh dấu một image được tự động phân giải là tương thích, và xác nhận rằng test vượt qua với kịch bản alias dựa trên Dockerfile được mô tả trong issue.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

type/bug

A custom ImageNameSubstitutor cannot be used to mark an image as compatible substitute for another image automatically, because all implementation I found call the compatibility assertion on their constructor argument, not on the image property from the parent class that actually applies the substitution.

I want to dynamically resolve images from a Dockerfile in the root of my project to allow Dependabot/Renovate to automatically update the images for me, and thus keep my tests up-to-date. For this I wanted to use short aliases and to set compatibility dynamically. However, this isn't possible for the reasons explained.

I'm filing this as a bug, because I believe that this isn't the intended behavior. Feel free to change this.

Ngôn ngữ chính
Java
Star
8.8k
Fork
2k
Merge trung bình
5 ngày 21 giờ
Pull request đã merge (30 ngày)
15

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của testcontainers/testcontainers-java

Tất cả issue của testcontainers/testcontainers-java

Issue tương tự

Thêm issue về Java

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.