标签: automation

如何在iOS模拟器中使用Instruments Automation?它无法附加或找到iOS模拟器

如何附加到当前在iOS模拟器6中运行的应用程序,或者使用Xcode Instruments中的Automation启动应用程序?我正在使用Xcode 4.5.我看到我的应用程序正在模拟器中运行.如果我启动Instruments,我选择"iOS模拟器 - >自动化"模板.然而,顶部的下拉告诉我在"附加到进程"下"当前工具不允许附加",并且在使用"选择目标"时,我从应用程序文件夹中显示了一个应用程序列表,但它们都不是iOS模拟器,因为它在Xcode.app包中.它在设备上运行得很好.

有任何想法吗?

xcode automation instruments ios

0
推荐指数
1
解决办法
2955
查看次数

如何自动化jcl在大型机上运行cobol程序

我们有一个COBOL批处理程序,我们可以从JCL手动执行.我们希望自动执行此过程,以便每15分钟执行一次.

有没有办法在大型机上自动执行批处理程序?

我是一个PC人,我知道在Windows中我可以创建一个.BAT文件,并在任务计划程序中将其设置为每15分钟运行一次.我本质上是想在大型机上做同样的事情.

automation mainframe batch-file jcl

0
推荐指数
1
解决办法
3965
查看次数

是否可以通过powershell for windows或绿色软件构建"自动点击器"?

我想自动化一些进程,基本上运行一些工具,单击菜单,从下拉列表中选择,然后复制并粘贴到notepad.exe应用程序以保存为txt文件 - 所有在Windows中.

但是我的公司环境可能不允许安装.

所以我想知道,如果有可能为此编写一个powershell脚本?

或者,如果有任何绿色软件不需要安装?最好的,如果它是开源的.

windows powershell automation open-source greensoftware

0
推荐指数
1
解决办法
3608
查看次数

使用Watir在div下面查找包含多个链接的文本

我试图验证链接的文本是否存在于.在单击链接之前,div不可用.单击链接后,可以单击更多链接.下面是单击以显示其他链接后html的样子.

<div class="more-links">
   <a href="url">First Link</a>
   <a href="url">Second Link</a>
   <a href="url">Third Link</a>
   <a href="url">Fourth Link</a>
   <a href="url">Fifth Link</a>
</div>
Run Code Online (Sandbox Code Playgroud)

我想确定在div出现后确保文本"Third Link"存在.

我试过了,但是watir说它无法找到那个元素.

assert_equal(true, browser.div(:class => "more-links").a(:text => "Third Link"))
Run Code Online (Sandbox Code Playgroud)

我可以找到这个文本,但是非常慢,并且想要指定这个特定的div

browser.text.include?("Third Link")
Run Code Online (Sandbox Code Playgroud)

思考?

ruby testing automation watir cucumber

0
推荐指数
1
解决办法
1389
查看次数

Powershell - 无法自动将凭据传递给gmail.com

我试图了解如何使用powershell来自动化IE导航,我在http://scriptolog.blogspot.com/2007/01/automated-web-forms.html找到了一个示例脚本

这是代码:

function Login-GMail{ 
    param(
        [string]$uname,
        [string]$url="http://www.gmail.com",
        [bool]$cookie=$false 
    ) 

    $creds = get-credential $uname 
    $pass = $creds.GetNetworkCredential().Password 
    $ie=new-object -com internetexplorer.application 
    $ie.visible=$true 
    $ie.navigate($url) 

    while($ie.ReadyState -ne 4){start-sleep -m 100}

    $ie.document.getElementbyId("Email").value=$creds
    $ie.document.getElementbyId("Passwd").value=$pass 
    $ie.document.getElementbyName("PersistentCookie") | foreach {$_.checked=$cookie}
    $ie.document.getElementbyId("gaia_loginform").submit()

} 
Login-Gmail
Run Code Online (Sandbox Code Playgroud)

代码看起来非常好,但它不能按预期工作

当我在命令行上运行它时,即C:\ sandbox\gmail.ps1 me@gmail.com我收到错误,

Set-Location : A positional parameter cannot be found that accepts argument 'me@gmail.com'.
At line:1 char:3
+ cd <<<<  c:\sandbox\gmail.ps1 p...@gmail.com
    + CategoryInfo          : InvalidArgument: (:) [Set-Location], ParameterBindingException
    + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.PowerShell.Commands.SetLocationCommand
Run Code Online (Sandbox Code Playgroud)

当我在Powershell GUI中运行它并按下绿色箭头时,弹出框会询问我的用户名和密码.但是,当它打开gmail.com时,它使用"System.Management.Automation.PSCredential"预填充用户名文本框,我收到以下错误

Method invocation failed because [mshtml.HTMLDocumentClass] doesn't …
Run Code Online (Sandbox Code Playgroud)

powershell internet-explorer automation

0
推荐指数
1
解决办法
2365
查看次数

"机器人框架"的"字符串库"中的"生成随机字符串"关键字,用于分配给变量

我需要生成随机数并将其分配给变量一次,以便以后多次使用它.我找到了关键字,Generate Random String但我不知道如何将它应用于我的案例.

testing random automation browser-automation robotframework

0
推荐指数
1
解决办法
9446
查看次数

使用Grunt&grunt-uncss在大型Magento网站上删除未使用的CSS样式

我使用了javascript任务运行程序Grunt来测试使用grunt-uncss从单个页面中删除未使用的CSS样式.这很好用,但是我试图确定在大型动态框架上使用它的最佳方法,例如Magento(它有数千个文件).

任何人都可以确定使用Grunt和Magento的最佳方法,而无需确定单个配置的负载吗?对此有任何建议将不胜感激.

javascript automation magento gruntjs

0
推荐指数
1
解决办法
1000
查看次数

如何通过单击带有Rails的按钮发送自动电子邮件?

Rails中有一种方法可以在提交表单时发送自动电子邮件,其中包含该表单中的信息吗?具体来说,我希望新用户在提交注册表单时收到包含他的新个人资料网址的电子邮件.

这是我的表单的样子:

<h1>Add Something!</h1>
<p>
  <%= form_for @thing, :url => things_path, :html => { :multipart => true } do |f| %>

    <%= f.text_field :name, :placeholder => "Name of the thing" %>
    <%= f.label :display_picture %>
    <%= f.file_field :avatar %>
    <br>
    <%= f.submit "Submit", class: "btn btn-primary" %>
  <% end %>
</p>
Run Code Online (Sandbox Code Playgroud)

控制器:

class ThingsController < ApplicationController

  def show
    @thing = Thing.find(params[:id])
  end

  def new
    @thing = Thing.new
    @things = Thing.all
  end

  def create
    @thing = Thing.new(thing_params)
    if @thing.save
      render :action …
Run Code Online (Sandbox Code Playgroud)

ruby email automation ruby-on-rails ruby-on-rails-4

0
推荐指数
1
解决办法
1687
查看次数

自动化Android应用程序按钮点击的方法

有没有办法自动点击(打开,单击应用程序的某个按钮,最后关闭它)与一些脚本或Android应用程序.

testing automation android click

0
推荐指数
1
解决办法
6040
查看次数

puppet覆盖模块上的文件资源

我正在使用这个CIS模块arildjensen/cis-puppet

并希望覆盖/etc/profileCIS模块上的文件声明

所以我在这篇文章之后创建了这个新的清单

class profile::hadoop::settings inherits cis {

      file { '/etc/profile':
        ensure => 'file',
        owner  => 'root',
        group  => 'root',
        mode   => '0600',
        source => 'puppet:///modules/profile/hadoop/etc/profile',
      }
  }
Run Code Online (Sandbox Code Playgroud)

但是这仍然会给出错误

Error: Duplicate declaration: File[/etc/profile] is already declared in file /tmp/vagrant-puppet/modules-ab9b45e51a68912cdc576c81d46a2260/profile/manifests/hadoop/settings.pp:9; cannot redeclare at /tmp/vagrant-puppet/modules-ab9b45e51a68912cdc576c81d46a2260/cis/manifests/linuxcontrols/c0076.pp:12 on node server.localdomain
Run Code Online (Sandbox Code Playgroud)

linux automation centos puppet

0
推荐指数
1
解决办法
6599
查看次数