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

15
LINES

< > BotCompany Repo | #1029650 // test_conceptsWithFieldLessThanOrEqualTo (indexed & non-indexed, OK)

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

Libraryless. Click here for Pure Java version (13669L/92K).

1  
concept Bla {
2  
  int a, b;
3  
}
4  
5  
svoid test_conceptsWithFieldLessThanOrEqualTo () {
6  
  new Concepts cc;
7  
  indexConceptFieldDesc(cc, Bla, "a");
8  
  Bla x = cnew(cc, Bla, a := 3, b := 3);
9  
  Bla y = cnew(cc, Bla, a := 5, b := 5);
10  
  for (int i : ll(7, 9))
11  
    cnew(cc, Bla, a := i, b := i);
12  
  assertEqualsVerbose(litset(x, y), asHashSet(conceptsWithFieldLessThanOrEqualTo(cc, Bla, a := 5)));
13  
  assertEqualsVerbose(litset(x, y), asHashSet(conceptsWithFieldLessThanOrEqualTo(cc, Bla, b := 5)));
14  
15  
}

Author comment

Began life as a copy of #1029648

download  show line numbers  debug dex  old transpilations   

Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1029650
Snippet name: test_conceptsWithFieldLessThanOrEqualTo (indexed & non-indexed, OK)
Eternal ID of this version: #1029650/1
Text MD5: bdff474d11e8ebb4dd21c4524af2dbf2
Transpilation MD5: c6a2c92004ed973123225091445c8a39
Author: stefan
Category: javax / concepts
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-09-04 20:56:19
Source code size: 498 bytes / 15 lines
Pitched / IR pitched: No / No
Views / Downloads: 151 / 237
Referenced in: [show references]