Node_Attributes initial checking (and lots of BDD refactoring) [1/1]

The model change for this pull is creating the HABTM between nodes and attributes.

Note: because attributes was already defined for nodes, the relationship
is expressed as Node.attribs

I also added the Scaffolding to support this.

There are a set of docs and BDD tests waiting for the API to arrive (next step)

I did some major refactoring of the BDD system to make it easier to create
API tests generically.

The BDD changes include
1) streamlined and fixed logging so that it is more consistent 
2) moved the generical REST methods to bdd_restrat
3) took advantage of the generic {object:foo} syntax in REST API steps
4) made the get/put/delete/post methods in EURL more consistent
5) made the returns from the when REST methods more consistent 
6) improved the logging and debugging for bdd_utils:is_a so it's much easier to figure out when JSON does not validate (see the barclamp.erl file)

It was a lot of small changes.  Enjoy.

ALSO - I realized that we don't need to use the Config passing pattern.  We should be using the 
erland BFFs for get and put instead.  I started to modify the existing 
bdd_utils:config wrappers to use these methods.  This will be a gradual change!


 crowbar_framework/BDD/bdd.erl                      |   32 +++--
 crowbar_framework/BDD/bdd_restrat.erl              |  145 +++++++++++++++++---
 crowbar_framework/BDD/bdd_utils.erl                |   59 ++++++--
 crowbar_framework/BDD/bdd_webrat.erl               |    6 +-
 crowbar_framework/BDD/crowbar.erl                  |    7 +-
 crowbar_framework/BDD/crowbar_rest.erl             |   63 +++------
 crowbar_framework/BDD/eurl.erl                     |   94 ++++++-------
 .../BDD/features/authenticate.feature              |    2 +-
 crowbar_framework/BDD/features/barclamp.feature    |   18 +++-
 crowbar_framework/BDD/features/cmdb.feature        |    1 -
 crowbar_framework/BDD/features/nodes.feature       |   40 ++++++-
 crowbar_framework/BDD/features/scaffolds.feature   |    9 ++
 crowbar_framework/BDD/features/support.feature     |    2 +-
 crowbar_framework/BDD/groups.erl                   |    8 +-
 crowbar_framework/BDD/simple_auth.erl              |    2 +-
 .../app/controllers/crowbar_controller.rb          |   21 ++-
 .../controllers/scaffolds/attributes_controller.rb |   19 +++
 .../app/controllers/scaffolds/nodes_controller.rb  |    1 +
 crowbar_framework/app/models/attribute.rb          |    2 +
 crowbar_framework/app/models/node.rb               |    1 +
 crowbar_framework/config/locales/crowbar/en.yml    |    1 +
 crowbar_framework/config/routes.rb                 |    1 +
 .../20120731225600_create_node_attributes.rb       |   23 +++
 .../db/migrate/20120801190200_scaffold_nav.rb      |    1 +
 .../doc/default/crowbar/devguide/api/node.md       |   40 ++++++
 .../doc/default/crowbar/devguide/testing/bdd.md    |    4 +-
 .../crowbar/devguide/testing/bdd/internals.md      |    3 +-
 .../test/unit/node_attribute_model_test.rb         |   92 +++++++++++++
 28 files changed, 540 insertions(+), 157 deletions(-)

Crowbar-Pull-ID: 7e180e7c385a03de075f7ef938023c9ec7bd2096

Crowbar-Release: development