Documentation ¶
Overview ¶
Package sharedfolders provides support for sharing folders with Crostini.
Index ¶
- Constants
- Variables
- type SharedFolders
- func (sf *SharedFolders) AddFolder(folder string) uiauto.Action
- func (sf *SharedFolders) CheckNoSharedFolders(cont *vm.Container, cr *chrome.Chrome) uiauto.Action
- func (sf *SharedFolders) ShareDriveOK(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
- func (sf *SharedFolders) ShareMyFiles(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
- func (sf *SharedFolders) ShareMyFilesOK(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
- func (sf *SharedFolders) Unshare(cr *chrome.Chrome, folders ...string) uiauto.Action
- func (sf *SharedFolders) UnshareAll(cont *vm.Container, cr *chrome.Chrome) uiauto.Action
Constants ¶
const ( ManageLinuxSharing = "Manage Linux sharing" DialogName = "Share folder with Linux" MountPath = "/mnt/chromeos" MountFolderMyFiles = "MyFiles" MountPathMyFiles = MountPath + "/" + MountFolderMyFiles MountFolderGoogleDrive = "GoogleDrive" MountPathGoogleDrive = MountPath + "/" + MountFolderGoogleDrive MountFolderMyDrive = "MyDrive" MountPathMyDrive = MountPathGoogleDrive + "/" + MountFolderMyDrive MountPathDownloads = MountPathMyFiles + "/" + filesapp.Downloads MountFolderPlay = "PlayFiles" MountPathPlay = MountPath + "/" + MountFolderPlay )
Folder sharing strings.
const ( MyFilesMsg = "Give Linux apps permission to access files in the My files folder" DriveMsg = "Give Linux apps permission to access files in your Google Drive. Changes will sync to your other devices." MyFiles = "My files" SharedDrive = filesapp.GoogleDrive + " › " + filesapp.MyDrive )
Strings for sharing My files.
Variables ¶
nodewith.Role(role.StaticText).Ancestor(shareConfirmDialog), OkButton: nodewith.Name("OK").Role(role.Button).Ancestor(shareConfirmDialog), CancelButton: nodewith.Name("Cancel").Role(role.Button).Ancestor(shareConfirmDialog), }Dialog: shareConfirmDialog, Msg:
ShareConfirmDialog represents an instance of the confirm dialog of sharing folder.
nodewith.Name("1 folder shared with Linux").Role(role.StaticText).Ancestor(toastNode), ManageButton: nodewith.Name("Manage").Role(role.Button), }Toast: toastNode, Msg:
ShareToastNotification represents an instance of the toast notification of sharing folder.
Functions ¶
This section is empty.
Types ¶
type SharedFolders ¶
type SharedFolders struct { // contains filtered or unexported fields }
SharedFolders provides support for actions and records on shared folders.
func NewSharedFolders ¶
func NewSharedFolders(tconn *chrome.TestConn) *SharedFolders
NewSharedFolders creates and returns a new Sharefolders instance.
func (*SharedFolders) AddFolder ¶
func (sf *SharedFolders) AddFolder(folder string) uiauto.Action
AddFolder adds shared folders into the map.
func (*SharedFolders) CheckNoSharedFolders ¶
CheckNoSharedFolders checks there are no folders listed in the Managed shared folders page.
func (*SharedFolders) ShareDriveOK ¶
func (sf *SharedFolders) ShareDriveOK(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
ShareDriveOK shares Google Drive with Crostini and clicks OK button on the confirmation dialog.
func (*SharedFolders) ShareMyFiles ¶
func (sf *SharedFolders) ShareMyFiles(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
ShareMyFiles clicks "Share with Linux" on My files.
func (*SharedFolders) ShareMyFilesOK ¶
func (sf *SharedFolders) ShareMyFilesOK(ctx context.Context, filesApp *filesapp.FilesApp) uiauto.Action
ShareMyFilesOK shares My files and clicks OK on the confirm dialog.
func (*SharedFolders) UnshareAll ¶
UnshareAll unshares all shared folders.