Make fields final
Closes gh-33537
This commit is contained in:
@@ -722,9 +722,9 @@ abstract class AbstractPackagerTests<P extends Packager> {
|
||||
|
||||
private static final Layer DEFAULT_LAYER = new Layer("default");
|
||||
|
||||
private Set<Layer> layers = new LinkedHashSet<>();
|
||||
private final Set<Layer> layers = new LinkedHashSet<>();
|
||||
|
||||
private Map<String, Layer> libraries = new HashMap<>();
|
||||
private final Map<String, Layer> libraries = new HashMap<>();
|
||||
|
||||
TestLayers() {
|
||||
this.layers.add(DEFAULT_LAYER);
|
||||
|
||||
@@ -30,7 +30,7 @@ import static org.mockito.Mockito.mock;
|
||||
*/
|
||||
class ImplicitLayerResolverTests {
|
||||
|
||||
private Layers layers = Layers.IMPLICIT;
|
||||
private final Layers layers = Layers.IMPLICIT;
|
||||
|
||||
@Test
|
||||
void iteratorReturnsLayers() {
|
||||
|
||||
@@ -60,7 +60,7 @@ class SizeCalculatingEntryWriterTests {
|
||||
|
||||
private static class TestEntryWriter implements EntryWriter {
|
||||
|
||||
private byte[] bytes;
|
||||
private final byte[] bytes;
|
||||
|
||||
TestEntryWriter(int size) {
|
||||
this.bytes = new byte[size];
|
||||
|
||||
Reference in New Issue
Block a user