Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

14
LINES

< > BotCompany Repo | #1034844 // test_HashedBWImage

JavaX fragment (include) [tags: use-pretranspiled]

Transpiled version (8663L) is out of date.

1  
svoid test_HashedBWImage() {
2  
  var img1 = randomImage(10);
3  
  var himg1 = new HashedBWImage(img1);
4  
  var himg2 = new HashedBWImage(img1);
5  
  assertEquals(himg1.hashCode(), himg2.hashCode());
6  
  assertEquals(himg1.hash(), himg2.hash());
7  
  assertEquals(himg1, himg2);
8  
  
9  
  var img3 = randomImage(10);
10  
  var himg3 = new HashedBWImage(img3);
11  
  assertNotEquals(himg1.hashCode(), himg3.hashCode());
12  
  assertNotEquals(himg1.hash(), himg3.hash());
13  
  assertNotEquals(himg1, himg3);
14  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1034844
Snippet name: test_HashedBWImage
Eternal ID of this version: #1034844/4
Text MD5: bed306d020ae3c75318d3f1b2e36ca9b
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-03-11 04:20:21
Source code size: 484 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 169 / 247
Version history: 3 change(s)
Referenced in: [show references]