Skip to content

Commit c49c935

Browse files
committed
agerange 0.0.2
1 parent a658267 commit c49c935

File tree

2 files changed

+58
-0
lines changed

2 files changed

+58
-0
lines changed

docs/agerange/changelog.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
### 2025.12.05 [v0.0.2]
2+
3+
```
4+
This release adds the ability to test using the "fake" results and also implements and defines error codes associated with the common errors.
5+
6+
### Updates
7+
8+
feat(android): add error codes and fake result implementation for testing
9+
feat(ios): add basic testing functionality to return fake result
10+
fix(docs): correct issues with asdocs generation
11+
```
12+
13+
### 2025.11.27 [v0.0.1]
14+
15+
```
16+
initial beta release
17+
```
18+

docs/agerange/usage.mdx

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,4 +129,44 @@ You can use this information to adapt your application experience accordingly.
129129

130130

131131

132+
## Testing
133+
134+
You can force the extension to return a specific result by using the `setFakeAgeRangeResult()` method.
135+
136+
<Tabs
137+
Id="platform"
138+
defaultValue="air"
139+
values={[
140+
{label: 'AIR', value: 'air'},
141+
]}>
142+
143+
<TabItem value="air" >
144+
145+
```actionscript
146+
var fakeResult:AgeRangeResult = new AgeRangeResult()
147+
.setAgeLower( 13 )
148+
.setAgeUpper( 15 )
149+
.setUserStatus( AgeRangeUserStatus.SUPERVISED )
150+
.setInstallId( "FAKE_INSTALL_ID_12345" );
151+
152+
AgeRange.instance.setFakeAgeRangeResult( fakeResult );
153+
```
154+
155+
</TabItem>
156+
<TabItem value="unity" >
157+
158+
</TabItem>
159+
</Tabs>
160+
161+
Then when you make an age range request the details in this fake result will be returned.
162+
163+
:::note Android
164+
On Android we construct a `FakeAgeSignalsManager` and pass in the parameters from your specified `AgeRangeResult` (as described in the [testing documentation](https://developer.android.com/google/play/age-signals/test-age-signals-api))
165+
:::
166+
167+
:::note iOS
168+
On iOS, there is no method in the Declared Age Range framework to set a test result.
169+
170+
Instead the specified `AgeRangeResult` will simply be returned in the success callback or event, which means you will not see any UI that would be presented during a normal operation.
171+
:::
132172

0 commit comments

Comments
 (0)