Class: Google::Apis::TestingV1::RegularFile
- Inherits:
-
Object
- Object
- Google::Apis::TestingV1::RegularFile
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/testing_v1/classes.rb,
lib/google/apis/testing_v1/representations.rb,
lib/google/apis/testing_v1/representations.rb
Overview
A file or directory to install on the device before the test starts.
Instance Attribute Summary collapse
-
#content ⇒ Google::Apis::TestingV1::FileReference
A reference to a file, used for user inputs.
-
#device_path ⇒ String
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ RegularFile
constructor
A new instance of RegularFile.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ RegularFile
Returns a new instance of RegularFile.
1920 1921 1922 |
# File 'lib/google/apis/testing_v1/classes.rb', line 1920 def initialize(**args) update!(**args) end |
Instance Attribute Details
#content ⇒ Google::Apis::TestingV1::FileReference
A reference to a file, used for user inputs.
Corresponds to the JSON property content
1903 1904 1905 |
# File 'lib/google/apis/testing_v1/classes.rb', line 1903 def content @content end |
#device_path ⇒ String
Required. Where to put the content on the device. Must be an absolute,
allowlisted path. If the file exists, it will be replaced. The following
device-side directories and any of their subdirectories are allowlisted: $
EXTERNAL_STORAGE
, /sdcard, or /storage $ANDROID_DATA
/local/tmp, or /data/
local/tmp Specifying a path outside of these directory trees is invalid. The
paths /sdcard and /data will be made available and treated as implicit path
substitutions. E.g. if /sdcard on a particular device does not map to external
storage, the system will replace it with the external storage path prefix for
that device and copy the file there. It is strongly advised to use the
Environment API in app and test code to access files on the device in a
portable way.
Corresponds to the JSON property devicePath
1918 1919 1920 |
# File 'lib/google/apis/testing_v1/classes.rb', line 1918 def device_path @device_path end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1925 1926 1927 1928 |
# File 'lib/google/apis/testing_v1/classes.rb', line 1925 def update!(**args) @content = args[:content] if args.key?(:content) @device_path = args[:device_path] if args.key?(:device_path) end |