Espere que STDOUT seja um CSV contendo determinados valores.
Uso
Cenário: Meu cenário de exemplo
Quando eu executar `wp term list post_tag --fields=name,slug --format=csv`
Então STDOUT deve ser um CSV contendo:
| name | slug |
| Test term | test |
A documentação das etapas do Behat é gerada a partir da base de código do WP-CLIWP-CLI WP-CLI é a Interface de Linha de Comando para WordPress, usada para realizar tarefas administrativas e de desenvolvimento de forma programática. A página do projeto é http://wp-cli.org/ https://make.wordpress.org/cli/ em cada versão. Para sugerir melhorias, envie uma solicitação pull.
Relacionados
- Then /^the return code should( not)? be (\d+)$/ – Espere um código de saída específico do comando anterior.
- Then /^(STDOUT|STDERR) should( strictly)? (be|contain|not contain):$/ – Verifique o conteúdo de STDOUT ou STDERR.
- Then /^(STDOUT|STDERR) should be a number$/ – Espere que STDOUT ou STDERR seja um valor numérico.
- Then /^(STDOUT|STDERR) should not be a number$/ – Espere que STDOUT ou STDERR não seja um valor numérico.
- Then /^STDOUT should be a table containing rows:$/ – Espere que STDOUT seja uma tabela contendo as linhas fornecidas.
- Then /^STDOUT should end with a table containing rows:$/ – Espere que STDOUT termine com uma tabela contendo as linhas fornecidas.
- Then /^STDOUT should be JSON containing:$/ – Espere uma saída JSONJSON JSON, ou JavaScript Object Notation, é um formato mínimo e legível para estruturar dados. Ele é usado principalmente para transmitir dados entre um servidor e uma aplicação web, como alternativa ao XML. válida em STDOUT.
- Then /^STDOUT should be a JSON array containing:$/ – Espere uma saída de array JSON válida em STDOUT.
- Then /^STDOUT should be YAML containing:$/ – Espere que STDOUT seja YAML contendo determinado conteúdo.
- Then /^(STDOUT|STDERR) should be empty$/ – Espere que STDOUT ou STDERR esteja vazio.
- Then /^(STDOUT|STDERR) should not be empty$/ – Espere que STDOUT ou STDERR não esteja vazio.
- Then /^(STDOUT|STDERR) should be a version string (<|<=|>|>=|==|=|!=|<>) ([+\w.{}-]+)$/ – Espere que STDOUT ou STDERR seja uma string de versão comparada à versão fornecida.
- Then /^the (.+) (file|directory) should( strictly)? (exist|not exist|be:|contain:|not contain:)$/ – Espere que determinado arquivo ou diretório exista ou não, ou contenha ou não determinado conteúdo.
- Then /^the contents of the (.+) file should( not)? match (((\/.+\/)|(#.+#))(“,”+)?)$/ – Compare o conteúdo do arquivo com uma expressão regular.[a-z]Then /^(STDOUT|STDERR) should( not)? match (((\/.+\/)|(#.+#))(“,”+)?)$/ – Compare STDOUT ou STDERR com uma expressão regular.
- Then /^an email should (be sent|not be sent)$/ – Espere que um e-mail seja enviado (ou não).[a-z]Then the HTTP status code should be :code – Espere que o código de status HTTP ao visitar `http://localhost:8080` seja :code.
- Then /^an email should (be sent|not be sent)$/ – Expect an email to be sent (or not).
- Then the HTTP status code should be :code – Expect the HTTP status code for visiting `http://localhost:8080`.