Skip to content

Add font attributes to testing E2E #14584

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 17 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "none",
"comment": "adding font attributes in test snapshots",
"packageName": "react-native-windows",
"email": "[email protected]",
"dependentChangeType": "none"
}
Original file line number Diff line number Diff line change
Expand Up @@ -1933,18 +1933,22 @@ const examples = [
return (
<View>
<RNTesterText
accessible
style={{
width: 500,
height: 100,
fontSize: 20,
backgroundColor: 'lightcoral',
padding: 10,
marginBottom: 10,
fontWeight: 200,
fontVariant: 'small-caps',
}}
testID="text-adjustfontsizetofit-default-a">
{`Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore Ut enim ad minim veniam.With AdjustFontSize width: 800, height: 100, fontSize: 20`}
</RNTesterText>
<RNTesterText
accessible
adjustsFontSizeToFit
style={{
width: 500,
Expand All @@ -1964,6 +1968,7 @@ const examples = [
].map((item, index) => (
<React.Fragment key={index}>
<RNTesterText
accessible
testID={`text-adjustfontsizetofit-${index}-a`}
numberOfLines={item.lineCount}
adjustsFontSizeToFit
Expand All @@ -1978,6 +1983,7 @@ const examples = [
{`Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore. With AdjustFontSize height:${item.height},width:${item.width},lineCount:${item.lineCount},fontSize:40`}
</RNTesterText>
<RNTesterText
accessible
testID={`text-adjustfontsizetofit-${index}-b`}
numberOfLines={item.lineCount}
style={{
Expand Down
Loading
Loading