Repository: dubzzz/fast-check
Pull request #1739 (2021-04-14 06:00:29)

🚚 Move tuple arbitraries into /arbitrary
<!-- Why is this PR for? -->
<!-- Describe the reason why you opened this PR or give a link towards the associated issue. -->

## In a nutshell

❌ New feature
❌ Fix an issue
❌ Documentation improvement
✔️ Other: *moving code*

(✔️: yes, ❌: no)

## Potential impacts

No impact is expected as IDE fail to import the right paths with auto-imports different from root.
Non-root import changed for tuple, genericTuple


codesandbox[bot]: This pull request is automatically built and testable in [CodeSandbox](https://codesandbox.io).

  To see build info of the built libraries, click [here](https://ci.codesandbox.io/status/dubzzz/fast-check/pr/1739/builds/119534) or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 8715dc904942d8c63b7568711d31de9872bf3753:

|Sandbox| Source |
|--|--|
|[Vanilla](https://codesandbox.io/s/vanilla-93qz4)| Configuration |
|[fast-check-examples](https://codesandbox.io/s/fast-check-examples-4wgey)| Configuration |

codecov[bot]: # [Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) Report
> Merging [#1739](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) (8715dc9) into [main](https://codecov.io/gh/dubzzz/fast-check/commit/e2864dc9341f0dae41d14095f7ad6fa66da0c31a?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) (e2864dc) will **decrease** coverage by `0.08%`.
> The diff coverage is `100.00%`.

[![Impacted file tree graph](https://codecov.io/gh/dubzzz/fast-check/pull/1739/graphs/tree.svg?width=650&height=150&src=pr&token=fRi2fJN730&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)

```diff
@@            Coverage Diff             @@
##             main    #1739      +/-   ##
==========================================
- Coverage   97.16%   97.08%   -0.09%     
==========================================
  Files         109      111       +2     
  Lines        3596     3599       +3     
  Branches      713      713              
==========================================
  Hits         3494     3494              
- Misses         98      101       +3     
  Partials        4        4              
```

| Flag | Coverage Δ | |
|---|---|---|
| unit-tests | `97.08% <100.00%> (-0.09%)` | :arrow_down: |
| unit-tests-10.x-Linux | `97.08% <100.00%> (-0.09%)` | :arrow_down: |
| unit-tests-12.x-Linux | `?` | |
| unit-tests-14.x-Linux | `97.08% <100.00%> (+<0.01%)` | :arrow_up: |

Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#carryforward-flags-in-the-pull-request-comment) to find out more.

| [Impacted Files](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) | Coverage Δ | |
|---|---|---|
| [src/arbitrary/\_internals/TupleArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9faW50ZXJuYWxzL1R1cGxlQXJiaXRyYXJ5LnRz) | `98.07% <100.00%> (ø)` | |
| [src/arbitrary/genericTuple.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9nZW5lcmljVHVwbGUudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/tuple.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS90dXBsZS50cw==) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/DictionaryArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9EaWN0aW9uYXJ5QXJiaXRyYXJ5LnRz) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/EmailArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9FbWFpbEFyYml0cmFyeS50cw==) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/FloatingPointArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9GbG9hdGluZ1BvaW50QXJiaXRyYXJ5LnRz) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/FunctionArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9GdW5jdGlvbkFyYml0cmFyeS50cw==) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/HostArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9Ib3N0QXJiaXRyYXJ5LnRz) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/IpArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9JcEFyYml0cmFyeS50cw==) | `100.00% <100.00%> (ø)` | |
| [src/check/arbitrary/ObjectArbitrary.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2NoZWNrL2FyYml0cmFyeS9PYmplY3RBcmJpdHJhcnkudHM=) | `97.34% <100.00%> (ø)` | |
| ... and [8 more](https://codecov.io/gh/dubzzz/fast-check/pull/1739/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN). Last update [e2864dc...8715dc9](https://codecov.io/gh/dubzzz/fast-check/pull/1739?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN).


Patch:
diff --git a/prebuild/property.cjs b/prebuild/property.cjs
index 3ebc297f..9dd0beda 100644
--- a/prebuild/property.cjs
+++ b/prebuild/property.cjs
@@ -41,7 +41,7 @@ const generateProperty = (num, isAsync) => {
   const blocks = [
     // imports
     `import { Arbitrary } from '../arbitrary/definition/Arbitrary';`,
-    `import { genericTuple } from '../arbitrary/TupleArbitrary';`,
+    `import { genericTuple } from '../../arbitrary/genericTuple';`,
     `import { ${className}, I${className}WithHooks } from './${className}.generic';`,
     // declare all signatures
     ...iota(num).map((id) => signatureFor(id + 1, isAsync)),
diff --git a/src/check/arbitrary/TupleArbitrary.ts b/src/arbitrary/_internals/TupleArbitrary.ts
similarity index 73%
rename from src/check/arbitrary/TupleArbitrary.ts
rename to src/arbitrary/_internals/TupleArbitrary.ts
index 674d5f10..e360c75f 100644
--- a/src/check/arbitrary/TupleArbitrary.ts
+++ b/src/arbitrary/_internals/TupleArbitrary.ts
@@ -1,10 +1,8 @@
 import { Random } from '../../random/generator/Random';
 import { Stream } from '../../stream/Stream';
-import { cloneIfNeeded, cloneMethod, WithCloneMethod } from '../symbols';
-import { Arbitrary } from './definition/Arbitrary';
-import { convertFromNext, convertToNext } from './definition/Converters';
-import { NextArbitrary } from './definition/NextArbitrary';
-import { NextValue } from './definition/NextValue';
+import { cloneIfNeeded, cloneMethod, WithCloneMethod } from '../../check/symbols';
+import { NextArbitrary } from '../../check/arbitrary/definition/NextArbitrary';
+import { NextValue } from '../../check/arbitrary/definition/NextValue';
 
 /** @internal */
 type ArbsArray<Ts extends unknown[]> = { [K in keyof Ts]: NextArbitrary<Ts[K]> };
@@ -85,32 +83,3 @@ export class GenericTupleArbitrary<Ts extends unknown[]> extends NextArbitrary<T
     return s;
   }
 }
-
-/**
- * For tuples produced by the provided `arbs`
- *
- * @param arbs - Ordered list of arbitraries
- *
- * @deprecated Switch to {@link tuple} instead
- * @remarks Since 1.0.0
- * @public
- */
-function genericTuple<Ts extends unknown[]>(arbs: { [K in keyof Ts]: Arbitrary<Ts[K]> }): Arbitrary<Ts> {
-  const nextArbs = arbs.map((arb) => convertToNext(arb)) as { [K in keyof Ts]: NextArbitrary<Ts[K]> };
-  return convertFromNext(new GenericTupleArbitrary<Ts>(nextArbs));
-}
-
-/**
- * For tuples produced using the provided `arbs`
- *
- * @param arbs - Ordered list of arbitraries
- *
- * @remarks Since 0.0.1
- * @public
- */
-function tuple<Ts extends unknown[]>(...arbs: { [K in keyof Ts]: Arbitrary<Ts[K]> }): Arbitrary<Ts> {
-  const nextArbs = arbs.map((arb) => convertToNext(arb)) as { [K in keyof Ts]: NextArbitrary<Ts[K]> };
-  return convertFromNext(new GenericTupleArbitrary<Ts>(nextArbs));
-}
-
-export { genericTuple, tuple };
diff --git a/src/arbitrary/genericTuple.ts b/src/arbitrary/genericTuple.ts
new file mode 100644
index 00000000..95ad8603
--- /dev/null
+++ b/src/arbitrary/genericTuple.ts
@@ -0,0 +1,18 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { convertFromNext, convertToNext } from '../check/arbitrary/definition/Converters';
+import { NextArbitrary } from '../check/arbitrary/definition/NextArbitrary';
+import { GenericTupleArbitrary } from './_internals/TupleArbitrary';
+
+/**
+ * For tuples produced by the provided `arbs`
+ *
+ * @param arbs - Ordered list of arbitraries
+ *
+ * @deprecated Switch to {@link tuple} instead
+ * @remarks Since 1.0.0
+ * @public
+ */
+export function genericTuple<Ts extends unknown[]>(arbs: { [K in keyof Ts]: Arbitrary<Ts[K]> }): Arbitrary<Ts> {
+  const nextArbs = arbs.map((arb) => convertToNext(arb)) as { [K in keyof Ts]: NextArbitrary<Ts[K]> };
+  return convertFromNext(new GenericTupleArbitrary<Ts>(nextArbs));
+}
diff --git a/src/arbitrary/tuple.ts b/src/arbitrary/tuple.ts
new file mode 100644
index 00000000..0845eceb
--- /dev/null
+++ b/src/arbitrary/tuple.ts
@@ -0,0 +1,17 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { convertFromNext, convertToNext } from '../check/arbitrary/definition/Converters';
+import { NextArbitrary } from '../check/arbitrary/definition/NextArbitrary';
+import { GenericTupleArbitrary } from './_internals/TupleArbitrary';
+
+/**
+ * For tuples produced using the provided `arbs`
+ *
+ * @param arbs - Ordered list of arbitraries
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+export function tuple<Ts extends unknown[]>(...arbs: { [K in keyof Ts]: Arbitrary<Ts[K]> }): Arbitrary<Ts> {
+  const nextArbs = arbs.map((arb) => convertToNext(arb)) as { [K in keyof Ts]: NextArbitrary<Ts[K]> };
+  return convertFromNext(new GenericTupleArbitrary<Ts>(nextArbs));
+}
diff --git a/src/check/arbitrary/DictionaryArbitrary.ts b/src/check/arbitrary/DictionaryArbitrary.ts
index 22a955f0..23dd4a35 100644
--- a/src/check/arbitrary/DictionaryArbitrary.ts
+++ b/src/check/arbitrary/DictionaryArbitrary.ts
@@ -1,7 +1,7 @@
 import { Arbitrary } from './definition/Arbitrary';
 
 import { set } from '../../arbitrary/set';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 
 /** @internal */
 export function toObject<T>(items: [string, T][]): { [key: string]: T } {
diff --git a/src/check/arbitrary/EmailArbitrary.ts b/src/check/arbitrary/EmailArbitrary.ts
index 4573e022..990ecb5b 100644
--- a/src/check/arbitrary/EmailArbitrary.ts
+++ b/src/check/arbitrary/EmailArbitrary.ts
@@ -2,7 +2,7 @@ import { array } from '../../arbitrary/array';
 import { buildLowerAlphaNumericArb } from './helpers/SpecificCharacterRange';
 import { domain } from './HostArbitrary';
 import { stringOf } from './StringArbitrary';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
 /**
diff --git a/src/check/arbitrary/FloatingPointArbitrary.ts b/src/check/arbitrary/FloatingPointArbitrary.ts
index 58283e8e..50be354f 100644
--- a/src/check/arbitrary/FloatingPointArbitrary.ts
+++ b/src/check/arbitrary/FloatingPointArbitrary.ts
@@ -2,7 +2,7 @@ import { Arbitrary } from './definition/Arbitrary';
 import { doubleNext, DoubleNextConstraints } from './DoubleNextArbitrary';
 import { floatNext, FloatNextConstraints } from './FloatNextArbitrary';
 import { integer } from '../../arbitrary/integer';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 
 /** @internal */
 function next(n: number): Arbitrary<number> {
diff --git a/src/check/arbitrary/FunctionArbitrary.ts b/src/check/arbitrary/FunctionArbitrary.ts
index 97b30a9c..efd78601 100644
--- a/src/check/arbitrary/FunctionArbitrary.ts
+++ b/src/check/arbitrary/FunctionArbitrary.ts
@@ -4,7 +4,7 @@ import { cloneMethod, hasCloneMethod } from '../symbols';
 import { array } from '../../arbitrary/array';
 import { Arbitrary } from './definition/Arbitrary';
 import { integer } from '../../arbitrary/integer';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { escapeForMultilineComments } from './helpers/TextEscaper';
 
 /**
diff --git a/src/check/arbitrary/HostArbitrary.ts b/src/check/arbitrary/HostArbitrary.ts
index a8f097b0..2e8c9a29 100644
--- a/src/check/arbitrary/HostArbitrary.ts
+++ b/src/check/arbitrary/HostArbitrary.ts
@@ -6,7 +6,7 @@ import {
 } from './helpers/SpecificCharacterRange';
 import { option } from '../../arbitrary/option';
 import { stringOf } from './StringArbitrary';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
 /** @internal */
diff --git a/src/check/arbitrary/IpArbitrary.ts b/src/check/arbitrary/IpArbitrary.ts
index 6303d4a6..601ac942 100644
--- a/src/check/arbitrary/IpArbitrary.ts
+++ b/src/check/arbitrary/IpArbitrary.ts
@@ -4,7 +4,7 @@ import { Arbitrary } from './definition/Arbitrary';
 import { nat } from '../../arbitrary/nat';
 import { oneof } from '../../arbitrary/oneof';
 import { hexaString } from './StringArbitrary';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 
 /**
  * For valid IP v4
diff --git a/src/check/arbitrary/ObjectArbitrary.ts b/src/check/arbitrary/ObjectArbitrary.ts
index e377b260..986c0685 100644
--- a/src/check/arbitrary/ObjectArbitrary.ts
+++ b/src/check/arbitrary/ObjectArbitrary.ts
@@ -12,7 +12,7 @@ import { memo, Memo } from './MemoArbitrary';
 import { oneof } from '../../arbitrary/oneof';
 import { set } from '../../arbitrary/set';
 import { string, unicodeString } from './StringArbitrary';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { bigInt } from '../../arbitrary/bigInt';
 import { date } from './DateArbitrary';
 import {
diff --git a/src/check/arbitrary/RecordArbitrary.ts b/src/check/arbitrary/RecordArbitrary.ts
index 8733d48a..92194c1a 100644
--- a/src/check/arbitrary/RecordArbitrary.ts
+++ b/src/check/arbitrary/RecordArbitrary.ts
@@ -1,7 +1,7 @@
 import { Arbitrary } from './definition/Arbitrary';
 
 import { option } from '../../arbitrary/option';
-import { genericTuple } from './TupleArbitrary';
+import { genericTuple } from '../../arbitrary/genericTuple';
 
 /**
  * Constraints to be applied on {@link record}
diff --git a/src/check/arbitrary/SparseArrayArbitrary.ts b/src/check/arbitrary/SparseArrayArbitrary.ts
index 2f078cf2..819c09eb 100644
--- a/src/check/arbitrary/SparseArrayArbitrary.ts
+++ b/src/check/arbitrary/SparseArrayArbitrary.ts
@@ -1,7 +1,7 @@
 import { Arbitrary } from './definition/Arbitrary';
 import { nat } from '../../arbitrary/nat';
 import { set } from '../../arbitrary/set';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { maxLengthFromMinLength } from '../../arbitrary/_internals/helpers/MaxLengthFromMinLength';
 
 /**
diff --git a/src/check/arbitrary/UuidArbitrary.ts b/src/check/arbitrary/UuidArbitrary.ts
index 81fe65f8..95a249fa 100644
--- a/src/check/arbitrary/UuidArbitrary.ts
+++ b/src/check/arbitrary/UuidArbitrary.ts
@@ -1,7 +1,7 @@
 import { Arbitrary } from './definition/Arbitrary';
 import { integer } from '../../arbitrary/integer';
 import { nat } from '../../arbitrary/nat';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 
 /** @internal */
 const padEight = (arb: Arbitrary<number>) => arb.map((n) => n.toString(16).padStart(8, '0'));
diff --git a/src/check/arbitrary/WebArbitrary.ts b/src/check/arbitrary/WebArbitrary.ts
index 0f104bd8..11682bbf 100644
--- a/src/check/arbitrary/WebArbitrary.ts
+++ b/src/check/arbitrary/WebArbitrary.ts
@@ -8,7 +8,7 @@ import { ipV4, ipV4Extended, ipV6 } from './IpArbitrary';
 import { oneof } from '../../arbitrary/oneof';
 import { option } from '../../arbitrary/option';
 import { stringOf } from './StringArbitrary';
-import { tuple } from './TupleArbitrary';
+import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
 /**
diff --git a/src/fast-check-default.ts b/src/fast-check-default.ts
index b8e58fe9..fde67995 100644
--- a/src/fast-check-default.ts
+++ b/src/fast-check-default.ts
@@ -77,7 +77,8 @@ import {
   unicodeString,
 } from './check/arbitrary/StringArbitrary';
 import { shuffledSubarray, subarray, SubarrayConstraints } from './check/arbitrary/SubarrayArbitrary';
-import { genericTuple, tuple } from './check/arbitrary/TupleArbitrary';
+import { genericTuple } from './arbitrary/genericTuple';
+import { tuple } from './arbitrary/tuple';
 import { uuid, uuidV } from './check/arbitrary/UuidArbitrary';
 import {
   webAuthority,


Test patch:
diff --git a/test/unit/check/arbitrary/TupleArbitrary.itest.spec.ts b/test/unit/arbitrary/_internals/TupleArbitrary.itest.spec.ts
similarity index 96%
rename from test/unit/check/arbitrary/TupleArbitrary.itest.spec.ts
rename to test/unit/arbitrary/_internals/TupleArbitrary.itest.spec.ts
index 418754dd..ab0e7d93 100644
--- a/test/unit/check/arbitrary/TupleArbitrary.itest.spec.ts
+++ b/test/unit/arbitrary/_internals/TupleArbitrary.itest.spec.ts
@@ -1,4 +1,4 @@
-import { tuple as tupleOld } from '../../../../src/check/arbitrary/TupleArbitrary';
+import { tuple as tupleOld } from '../../../../src/arbitrary/tuple';
 
 import { convertFromNext, convertToNext } from '../../../../src/check/arbitrary/definition/Converters';
 import { Arbitrary } from '../../../../src/check/arbitrary/definition/Arbitrary';
@@ -8,7 +8,7 @@ import { Random } from '../../../../src/random/generator/Random';
 import { Stream } from '../../../../src/stream/Stream';
 
 import * as stubRng from '../../stubs/generators';
-import { buildNextShrinkTree, renderTree, walkTree } from './generic/ShrinkTree';
+import { buildNextShrinkTree, renderTree, walkTree } from '../../check/arbitrary/generic/ShrinkTree';
 import {
   assertGenerateProducesCorrectValues,
   assertGenerateProducesSameValueGivenSameSeed,
@@ -17,8 +17,8 @@ import {
   assertShrinkProducesSameValueWithoutInitialContext,
   assertShrinkProducesStrictlySmallerValue,
   assertShrinkProducesValuesFlaggedAsCanGenerate,
-} from './generic/NextArbitraryAssertions';
-import { FakeIntegerArbitrary } from './generic/NextArbitraryHelpers';
+} from '../../check/arbitrary/generic/NextArbitraryAssertions';
+import { FakeIntegerArbitrary } from '../../check/arbitrary/generic/NextArbitraryHelpers';
 import { cloneMethod } from '../../../../src/check/symbols';
 
 const mrngNoCall = stubRng.mutable.nocall();
diff --git a/test/unit/check/arbitrary/TupleArbitrary.utest.spec.ts b/test/unit/arbitrary/_internals/TupleArbitrary.utest.spec.ts
similarity index 98%
rename from test/unit/check/arbitrary/TupleArbitrary.utest.spec.ts
rename to test/unit/arbitrary/_internals/TupleArbitrary.utest.spec.ts
index 93ad38d6..5d5c9351 100644
--- a/test/unit/check/arbitrary/TupleArbitrary.utest.spec.ts
+++ b/test/unit/arbitrary/_internals/TupleArbitrary.utest.spec.ts
@@ -1,4 +1,4 @@
-import { tuple as tupleOld } from '../../../../src/check/arbitrary/TupleArbitrary';
+import { tuple as tupleOld } from '../../../../src/arbitrary/tuple';
 
 import { convertFromNext, convertToNext } from '../../../../src/check/arbitrary/definition/Converters';
 import { Arbitrary } from '../../../../src/check/arbitrary/definition/Arbitrary';
@@ -7,7 +7,7 @@ import { NextValue } from '../../../../src/check/arbitrary/definition/NextValue'
 
 import * as stubRng from '../../stubs/generators';
 
-import { fakeNextArbitrary } from './generic/NextArbitraryHelpers';
+import { fakeNextArbitrary } from '../../check/arbitrary/generic/NextArbitraryHelpers';
 import { cloneMethod, hasCloneMethod } from '../../../../src/check/symbols';
 import { Stream } from '../../../../src/stream/Stream';
 
diff --git a/test/unit/check/arbitrary/SparseArrayArbitrary.utest.spec.ts b/test/unit/check/arbitrary/SparseArrayArbitrary.utest.spec.ts
index 0240a314..d3205ce4 100644
--- a/test/unit/check/arbitrary/SparseArrayArbitrary.utest.spec.ts
+++ b/test/unit/check/arbitrary/SparseArrayArbitrary.utest.spec.ts
@@ -6,12 +6,12 @@ import { mocked } from 'ts-jest/utils';
 import fc from '../../../../lib/fast-check';
 
 import * as NatMock from '../../../../src/arbitrary/nat';
-import * as SetArbitraryMock from '../../../../src/arbitrary/set';
-import * as TupleArbitraryMock from '../../../../src/check/arbitrary/TupleArbitrary';
+import * as SetMock from '../../../../src/arbitrary/set';
+import * as TupleMock from '../../../../src/arbitrary/tuple';
 import { arbitraryFor } from './generic/ArbitraryBuilder';
 jest.mock('../../../../src/arbitrary/nat');
 jest.mock('../../../../src/arbitrary/set');
-jest.mock('../../../../src/check/arbitrary/TupleArbitrary');
+jest.mock('../../../../src/arbitrary/tuple');
 
 const validSparseArrayConstraints = (removedKeys: (keyof SparseArrayConstraints)[] = []) =>
   fc
@@ -63,8 +63,8 @@ describe('SparseArrayArbitrary', () => {
           .property(fc.option(validSparseArrayConstraints(), { nil: undefined }), (ct) => {
             // Arrange
             fc.pre(!isLimitNoTrailingCase(ct));
-            const { set } = mocked(SetArbitraryMock);
-            const { tuple } = mocked(TupleArbitraryMock);
+            const { set } = mocked(SetMock);
+            const { tuple } = mocked(TupleMock);
             set.mockImplementationOnce(() => arbitraryFor([{ value: [] }]));
             tuple.mockImplementationOnce(() => arbitraryFor([{ value: [] as any }]));
 
@@ -90,8 +90,8 @@ describe('SparseArrayArbitrary', () => {
           .property(fc.option(validSparseArrayConstraints(), { nil: undefined }), (ct) => {
             // Arrange
             fc.pre(!isLimitNoTrailingCase(ct));
-            const { set } = mocked(SetArbitraryMock);
-            const { tuple } = mocked(TupleArbitraryMock);
+            const { set } = mocked(SetMock);
+            const { tuple } = mocked(TupleMock);
             const { nat } = mocked(NatMock); // called to build indexes
             set.mockImplementationOnce(() => arbitraryFor([{ value: [] }]));
             tuple.mockImplementationOnce(() => arbitraryFor([{ value: [] as any }]));
diff --git a/test/unit/check/arbitrary/UuidArbitrary.utest.spec.ts b/test/unit/check/arbitrary/UuidArbitrary.utest.spec.ts
index a468797e..d0f2085b 100644
--- a/test/unit/check/arbitrary/UuidArbitrary.utest.spec.ts
+++ b/test/unit/check/arbitrary/UuidArbitrary.utest.spec.ts
@@ -5,10 +5,10 @@ import { ArbitraryWithShrink } from '../../../../src/check/arbitrary/definition/
 
 jest.mock('../../../../src/arbitrary/integer');
 jest.mock('../../../../src/arbitrary/nat');
-jest.mock('../../../../src/check/arbitrary/TupleArbitrary');
+jest.mock('../../../../src/arbitrary/tuple');
 import * as _IntegerMock from '../../../../src/arbitrary/integer';
 import * as _NatMock from '../../../../src/arbitrary/nat';
-import * as TupleArbitraryMock from '../../../../src/check/arbitrary/TupleArbitrary';
+import * as TupleMock from '../../../../src/arbitrary/tuple';
 import { arbitraryFor } from './generic/ArbitraryBuilder';
 
 const IntegerMock: { integer: (min: number, max: number) => ArbitraryWithShrink<number> } = _IntegerMock;
@@ -25,7 +25,7 @@ describe('UuidArbitrary', () => {
       // Arrange
       const { integer } = mocked(IntegerMock);
       const { nat } = mocked(NatMock);
-      const { tuple } = mocked(TupleArbitraryMock);
+      const { tuple } = mocked(TupleMock);
       nat.mockImplementation(() => arbitraryFor([{ value: 0 }, { value: 0 }, { value: 0 }]));
       integer.mockImplementation((a, _b) => arbitraryFor([{ value: a }]));
       tuple.mockImplementation((...arbs) =>
@@ -44,7 +44,7 @@ describe('UuidArbitrary', () => {
       // Arrange
       const { integer } = mocked(IntegerMock);
       const { nat } = mocked(NatMock);
-      const { tuple } = mocked(TupleArbitraryMock);
+      const { tuple } = mocked(TupleMock);
       nat.mockImplementation((a) => arbitraryFor([{ value: a }, { value: a }, { value: a }]));
       integer.mockImplementation((a, b) => arbitraryFor([{ value: b }]));
       tuple.mockImplementation((...arbs) =>
@@ -68,7 +68,7 @@ describe('UuidArbitrary', () => {
       // Arrange
       const { integer } = mocked(IntegerMock);
       const { nat } = mocked(NatMock);
-      const { tuple } = mocked(TupleArbitraryMock);
+      const { tuple } = mocked(TupleMock);
       nat.mockImplementation(() => arbitraryFor([{ value: 0 }, { value: 0 }]));
       integer.mockImplementation((a, _b) => arbitraryFor([{ value: a }]));
       tuple.mockImplementation((...arbs) =>
@@ -87,7 +87,7 @@ describe('UuidArbitrary', () => {
       // Arrange
       const { integer } = mocked(IntegerMock);
       const { nat } = mocked(NatMock);
-      const { tuple } = mocked(TupleArbitraryMock);
+      const { tuple } = mocked(TupleMock);
       nat.mockImplementation((a) => arbitraryFor([{ value: a }, { value: a }]));
       integer.mockImplementation((a, b) => arbitraryFor([{ value: b }]));
       tuple.mockImplementation((...arbs) =>
diff --git a/test/unit/check/arbitrary/definition/Arbitrary.itest.spec.ts b/test/unit/check/arbitrary/definition/Arbitrary.itest.spec.ts
index ca3f845d..94bc7ff2 100644
--- a/test/unit/check/arbitrary/definition/Arbitrary.itest.spec.ts
+++ b/test/unit/check/arbitrary/definition/Arbitrary.itest.spec.ts
@@ -4,7 +4,7 @@ import { constant } from '../../../../../src/check/arbitrary/ConstantArbitrary';
 import { Arbitrary } from '../../../../../src/check/arbitrary/definition/Arbitrary';
 import { Shrinkable } from '../../../../../src/check/arbitrary/definition/Shrinkable';
 import { nat } from '../../../../../src/arbitrary/nat';
-import { tuple } from '../../../../../src/check/arbitrary/TupleArbitrary';
+import { tuple } from '../../../../../src/arbitrary/tuple';
 import { Random } from '../../../../../src/random/generator/Random';
 import { stream } from '../../../../../src/stream/Stream';
 
diff --git a/test/unit/check/model/commands/CommandsArbitrary.spec.ts b/test/unit/check/model/commands/CommandsArbitrary.spec.ts
index 9da763c2..ec0fa6df 100644
--- a/test/unit/check/model/commands/CommandsArbitrary.spec.ts
+++ b/test/unit/check/model/commands/CommandsArbitrary.spec.ts
@@ -5,7 +5,7 @@ import { Command } from '../../../../../src/check/model/command/Command';
 import { Random } from '../../../../../src/random/generator/Random';
 import { constant } from '../../../../../src/check/arbitrary/ConstantArbitrary';
 import { commands } from '../../../../../src/check/model/commands/CommandsArbitrary';
-import { genericTuple } from '../../../../../src/check/arbitrary/TupleArbitrary';
+import { genericTuple } from '../../../../../src/arbitrary/genericTuple';
 import { nat } from '../../../../../src/arbitrary/nat';
 import { Arbitrary } from '../../../../../src/check/arbitrary/definition/Arbitrary';
 import { Shrinkable } from '../../../../../src/check/arbitrary/definition/Shrinkable';