-
Notifications
You must be signed in to change notification settings - Fork 3.2k
[camera_avfoundation] Tests backfilling - part 4 #8854
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
[camera_avfoundation] Tests backfilling - part 4 #8854
Conversation
ace2d95
to
0710a0f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
overall looks good
...es/camera/camera_avfoundation/example/ios/RunnerTests/Mocks/MockCaptureVideoDataOutput.swift
Outdated
Show resolved
Hide resolved
packages/camera/camera_avfoundation/example/ios/RunnerTests/SampleBufferTests.swift
Show resolved
Hide resolved
...mera_avfoundation/ios/camera_avfoundation/Sources/camera_avfoundation/FLTCaptureConnection.m
Outdated
Show resolved
Hide resolved
/// The underlying instance of `AVCaptureVideoDataOutput`. | ||
@property(nonatomic, readonly) AVCaptureVideoDataOutput *avOutput; | ||
|
||
@property(nonatomic) BOOL alwaysDiscardsLateVideoFrames; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these all need doc comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What kind of comment do you have in mind? More "Corresponds to the alwaysDiscardsLateVideoFrames property of the wrapped AVCaptureVideoDataOutput" or a copy of the comment from the AVCaptureVideoDataOutput so that docs are quick to access despite the additional wrapper?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Either seems reasonable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added the former. IMO those comments are mostly pointless. What else can a wrapper method do besides calling the equivalent in the wrapped instance? The latter would make more sense but I'm not sure how copyright/licensing around apple documentation works in this case so I don't want to copy it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO those comments are mostly pointless.
FWIW, I agree. I'm a stickler for enforcing the style guide's requirements for declaration comments in my reviews, but for protocols/classes that are documented at the class level explicitly as being direct passthroughs I have been making an exception since in that specific context I don't think they are adding anything.
The latter would make more sense but I'm not sure how copyright/licensing around apple documentation works in this case so I don't want to copy it
If we are going to put comments, maybe they should just be links to the actual Apple docs for the method.
0710a0f
to
c515c6f
Compare
c515c6f
to
db239d1
Compare
auto label is removed for flutter/packages/8854, Failed to merge flutter/packages/8854 with Pull request flutter/packages/8854 could not be merged: Merge already in progress. |
flutter/packages@d450e1b...dd781d4 2025-03-19 [email protected] [camera_avfoundation] Tests backfilling - part 4 (flutter/packages#8854) 2025-03-18 [email protected] [camera_avfoundation] Tests backfilling - part 5 (flutter/packages#8873) 2025-03-18 [email protected] [video_player]: reduce video player position update interval from 500ms to 100ms (flutter/packages#8346) 2025-03-18 [email protected] [google_maps_flutter] Support for Ground Overlay (flutter/packages#8432) 2025-03-18 [email protected] [google_maps_flutter] Ground overlay support - platform impls (flutter/packages#8563) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Backfills tests for the
FLTCam
class as part of flutter/flutter#119109Adds tests for the
setDeviceOrientation
method of theFLTCam
class. I had to addFLTCaptureVideoDataOutput
andFLTCaptureOutput
wrappers around AVFoundation classes to make it mockable (similar to the existingFLTCapturePhotoOutput
wrapper)Pre-Review Checklist
dart format
.)[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or I have commented below to indicate which version change exemption this PR falls under.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style, or I have commented below to indicate which CHANGELOG exemption this PR falls under.///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.