diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2025-04-22 16:12:21 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2025-04-22 16:12:21 +0200 |
| commit | bab22e1946a656088804b61cf765461b48744971 (patch) | |
| tree | 43ae3798e5c2f4fc63e68df72d134e742fcaf834 /test/101_cocsep_transform_invariant | |
| parent | 93522effba2f200257141189de5925a23fca93b8 (diff) | |
| download | nissy-core-bab22e1946a656088804b61cf765461b48744971.tar.gz nissy-core-bab22e1946a656088804b61cf765461b48744971.zip | |
Update tests for oriented_cube_t
Diffstat (limited to 'test/101_cocsep_transform_invariant')
| -rw-r--r-- | test/101_cocsep_transform_invariant/cocsep_transform_invariant.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c b/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c index 7ded2e9..5553fd1 100644 --- a/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c +++ b/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c | |||
| @@ -11,7 +11,8 @@ void run(void) { | |||
| 11 | uint64_t selfsim[COCSEP_CLASSES]; | 11 | uint64_t selfsim[COCSEP_CLASSES]; |
| 12 | int64_t coord, tcoord; | 12 | int64_t coord, tcoord; |
| 13 | char str[STRLENMAX]; | 13 | char str[STRLENMAX]; |
| 14 | cube_t cube, transd, rep[COCSEP_CLASSES]; | 14 | oriented_cube_t cube; |
| 15 | cube_t rep[COCSEP_CLASSES], transd; | ||
| 15 | 16 | ||
| 16 | fgets(str, STRLENMAX, stdin); | 17 | fgets(str, STRLENMAX, stdin); |
| 17 | cube = readcube(str); | 18 | cube = readcube(str); |
| @@ -19,9 +20,9 @@ void run(void) { | |||
| 19 | gendata_cocsep(buf, selfsim, rep); | 20 | gendata_cocsep(buf, selfsim, rep); |
| 20 | cocsepdata = (uint32_t *)((char *)buf + INFOSIZE); | 21 | cocsepdata = (uint32_t *)((char *)buf + INFOSIZE); |
| 21 | 22 | ||
| 22 | coord = (int64_t)COCLASS(cocsepdata[coord_cocsep(cube)]); | 23 | coord = (int64_t)COCLASS(cocsepdata[coord_cocsep(cube.cube)]); |
| 23 | for (t = 0; t < 48; t++) { | 24 | for (t = 0; t < 48; t++) { |
| 24 | transd = transform(cube, t); | 25 | transd = transform(cube.cube, t); |
| 25 | tcoord = (int64_t)COCLASS(cocsepdata[coord_cocsep(transd)]); | 26 | tcoord = (int64_t)COCLASS(cocsepdata[coord_cocsep(transd)]); |
| 26 | if (coord != tcoord) | 27 | if (coord != tcoord) |
| 27 | printf("Error: expected %" PRId64 | 28 | printf("Error: expected %" PRId64 |
