Files
inji-wallet/components/__snapshots__/TrustModal.test.tsx.snap
Kaushik Gupta 33c6caa08a INJIMOB-3246 Code coverage for Inji-Wallet repo increase above 5% (#2108)
* INJIMOB-3246 Code coverage for Inji-Wallet repo increase above 5%

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* INJIMOB-3246: added snapshot tests and coverage increased to +4%

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* removed duplicated lines

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* Added updateCredentialInformation tests

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* added code rabbit changes

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* removed platform-specific tests without mocking

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

* standardize mocks in VcItemContainerProfileImage tests

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>

---------

Signed-off-by: Kaushik Gupta <kausgpt97@gmail.com>
2025-11-07 11:10:37 +05:30

1288 lines
29 KiB
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`TrustModal Component should match snapshot when not visible 1`] = `null`;
exports[`TrustModal Component should match snapshot with issuer flow 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "center",
"marginBottom": 16,
"padding": 10,
}
}
>
<Image
source={
{
"uri": "https://example.com/logo.png",
}
}
style={
{
"height": 60,
"resizeMode": "contain",
"width": 60,
}
}
/>
<Text
style={
{
"fontSize": 16,
"fontWeight": "bold",
"marginTop": 8,
}
}
>
Test Issuer
</Text>
</View>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
description
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;
exports[`TrustModal Component should match snapshot with long name 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "center",
"marginBottom": 16,
"padding": 10,
}
}
>
<Image
source={
{
"uri": "https://example.com/logo.png",
}
}
style={
{
"height": 60,
"resizeMode": "contain",
"width": 60,
}
}
/>
<Text
style={
{
"fontSize": 16,
"fontWeight": "bold",
"marginTop": 8,
}
}
>
Very Long Issuer Name That Should Wrap Properly
</Text>
</View>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
verifierDescription
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;
exports[`TrustModal Component should match snapshot with verifier flow 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "center",
"marginBottom": 16,
"padding": 10,
}
}
>
<Image
source={
{
"uri": "https://example.com/logo.png",
}
}
style={
{
"height": 60,
"resizeMode": "contain",
"width": 60,
}
}
/>
<Text
style={
{
"fontSize": 16,
"fontWeight": "bold",
"marginTop": 8,
}
}
>
Test Issuer
</Text>
</View>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
verifierDescription
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;
exports[`TrustModal Component should match snapshot without logo 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "center",
"marginBottom": 16,
"padding": 10,
}
}
>
<Text
style={
{
"fontSize": 16,
"fontWeight": "bold",
"marginTop": 8,
}
}
>
Test Issuer
</Text>
</View>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
description
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;
exports[`TrustModal Component should match snapshot without logo and name 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
description
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;
exports[`TrustModal Component should match snapshot without name 1`] = `
<Modal
animationType="fade"
hardwareAccelerated={false}
transparent={true}
visible={true}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "rgba(0, 0, 0, 0.5)",
"flex": 1,
"justifyContent": "center",
"padding": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"backgroundColor": "#fff",
"borderRadius": 20,
"height": 470,
"padding": 20,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "center",
"marginBottom": 16,
"padding": 10,
}
}
>
<Image
source={
{
"uri": "https://example.com/logo.png",
}
}
style={
{
"height": 60,
"resizeMode": "contain",
"width": 60,
}
}
/>
</View>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "center",
"paddingBottom": 10,
}
}
showsVerticalScrollIndicator={true}
style={
{
"flex": 1,
"width": "100%",
}
}
>
<View>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"lineHeight": 20,
"marginBottom": 16,
"textAlign": "center",
}
}
>
description
</Text>
<View
style={
{
"marginBottom": 10,
"width": "100%",
}
}
>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 1
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 2
</Text>
</View>
<View
style={
{
"alignItems": "flex-start",
"flexDirection": "row",
"marginBottom": 6,
"paddingHorizontal": 4,
}
}
>
<Text
style={
{
"color": "#666",
"fontSize": 14,
"marginRight": 8,
"marginTop": 1,
}
}
>
</Text>
<Text
style={
{
"color": "#666",
"flex": 1,
"fontSize": 14,
"lineHeight": 18,
}
}
>
Point 3
</Text>
</View>
</View>
</View>
</RCTScrollView>
<View
style={
{
"paddingBottom": 5,
"paddingTop": 10,
"width": "100%",
}
}
/>
</View>
</View>
</Modal>
`;