Skip to content

--exclude flag does not accept an array as expected #50

Description

@Genkilabs

Per the docs, adding a space-delimited list of strings to the --exclude flag seems to cause the last parameter, the host, to be gobbled by the array. Singly the --exclude seems to work.

I tested this against a new Rails server with nothing in the routes except failure statuses expecting to be able to isolate specific routes as I implemented them. For example:

# GET /resources/:id/measures
def measures
	render :json => {:message => "Not yet implemented"}, :status => :not_implemented
end

Single param working example:

grafton test --product=bonnets --plan=small --region=aws::us-east-1 \
    --client-id=21jtaatqj8y5t0kctb2ejr6jev5w8 \
    --client-secret=3yTKSiJ6f5V5Bq-kWF0hmdrEUep3m3HKPTcPX7CdBZw \
    --connector-port=3001 \
    --new-plan=large \
    --exclude plan-change sso \
    http://localhost:3000

The above works great!

However if you add additional exclusions the host is lost

> grafton test --product=bonnets --plan=small --region=aws::us-east-1 \
     --client-id=21jtaatqj8y5t0kctb2ejr6jev5w8 \
     --client-secret=3yTKSiJ6f5V5Bq-kWF0hmdrEUep3m3HKPTcPX7CdBZw \
     --connector-port=3001 \
     --new-plan=large \
     --exclude plan-change sso \
     http://localhost:3000

cleanup: Remove dangling resource due to failed provision
  Default case
    Expected a successful provision of a resource
    http: no Host in request URL
  Default case ✗
provision: Provision a resource
  Default case
    Expected a successful provision of a resource
    http: no Host in request URL
  Default case ✗

2 features, 2 failures

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions