All tests

Plugin

Test report

  1. Global function tangible_loops_for_woocommerce

      exists
      returns an instance of the plugin

All 1 test passed

Product

Test report

  1. Product loop config

      exists as loop type woo_product
      has property "name"
      has property "title"
      has property "category"
      has property "description"
      has property "query_args"
      has property "fields"

  2. Product loop type

      can create loop type woo_product
      returns products from method get_items()
      returns an instance of WooCommerce product

  3. Product loop item

      loop has next item
      loops every item
      loop can be reset
      has current item

  4. Product fields

      ID
      sku (specified field)
      weight (unspecified field)
      purchased status

  5. Product logic

      purchased status
      grants access to team status

  6. Product subloops

      product variations returns a Loop
      return product variations correctly
      product subscriptions returns a Loop
      returns items from get_field('subscriptions')
      returns instances of WC_Subscription from subscribers field
      returns active subscriptions correctly

  7. Product query args

      Filtering by membership ID returns corresponding products

Total of 7 tests: 6 passed, 1 failed

Order

Test report

  1. Order loop config

      exists as loop type woo_order
      has property "name"
      has property "title"
      has property "category"
      has property "description"
      has property "query_args"
      has property "fields"

  2. Order loop type

      can create loop type woo_order
      returns orders from method get_items()
      returns an instance of WooCommerce order

  3. Order loop item

      loop has next item
      loops every item
      loop can be reset
      has current item

  4. Order subloops

      members returns a Loop
      returns items correctly

  5. Order fields

      ID
      Checking status
      Checking order_number
      Checking billing_country
      Checking currency
      Checking total
      Checking item_count

All 5 tests passed

Membership

Test report

  1. Membership loop config

      exists as loop type woo_membership
      has property "name"
      has property "title"
      has property "category"
      has property "description"
      has property "query_args"
      has property "fields"

  2. Membership loop type

      can create loop type woo_membership
      returns memberships from method get_items()
      returns an instance of WooCommerce membership

  3. Membership loop item

      loop has next item
      loops every item
      loop can be reset
      has current item

  4. Membership fields

      ID
      formatted name
      access method
      active status

  5. Membership logic

      active status

  6. Membership subloops

      members returns a Loop
      returns users from get_field('members')
      returns an instance of WP_User from members field
      returns active members correctly

Total of 6 tests: 5 passed, 1 failed

Subscription

Test report

  1. Subscription loop config

      exists as loop type woo_subscription
      has property "name"
      has property "title"
      has property "category"
      has property "description"
      has property "query_args"
      has property "fields"

  2. Subscription loop type

      can create loop type woo_subscription
      returns subscriptions from method get_items()
      returns an instance of WooCommerce subscription

  3. Subscription loop item

      loop has next item
      loops every item
      loop can be reset
      has current item

  4. Subscription fields

      ID
      status
      billing period
      date: next payment

  5. Subscription subloops

      subscriber returns a Loop
      returns a 1-sized loop from subscriber field
      returns an instance of WP_User from subscriber loop
      returns subscriber correctly

  6. Subscription query args

      return user subscriptions when user param is specified

Total of 6 tests: 5 passed, 1 failed