Left: | ||
Right: |
OLD | NEW |
---|---|
1 'use strict'; | 1 'use strict'; |
2 | 2 |
3 /** | 3 /** |
4 * Provide the Charm and CharmList classes. | 4 * Provide the Charm and CharmList classes. |
5 * | 5 * |
6 * @module models | 6 * @module models |
7 * @submodule models.charm | 7 * @submodule models.charm |
8 */ | 8 */ |
9 | 9 |
10 YUI.add('juju-charm-models', function(Y) { | 10 YUI.add('juju-charm-models', function(Y) { |
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
389 * log, revisions, etc. | 389 * log, revisions, etc. |
390 * | 390 * |
391 * @attribute code_source | 391 * @attribute code_source |
392 * @default undefined | 392 * @default undefined |
393 * @type {Object} | 393 * @type {Object} |
394 * | 394 * |
395 */ | 395 */ |
396 code_source: {}, | 396 code_source: {}, |
397 date_created: {}, | 397 date_created: {}, |
398 description: {}, | 398 description: {}, |
399 'failingProviders': { | |
400 /** | |
401 * @method failingProviders.valueFn | |
402 * @return {Array} the list of failing provider names. | |
403 * | |
404 */ | |
405 valueFn: function() { | |
406 var failing = [], | |
407 providers = this.get('tested_providers'); | |
408 Y.Object.each(providers, function(value, key) { | |
409 if (value !== 'SUCCESS') { | |
410 failing.push(key); | |
411 | |
412 // We test openstack on HP. If it fails on openstack, it's | |
413 // failing on HP as well so add that. | |
414 if (key === 'openstack') { | |
415 failing.push('hp'); | |
j.c.sackett
2013/04/29 15:06:22
Does this mean that HP cannot independently fail?
rharding
2013/04/29 15:09:52
Correct. According to the juju test people: the op
| |
416 } | |
417 } | |
418 }); | |
419 | |
420 if (failing.length > 0) { | |
421 | |
422 return failing; | |
423 } else { | |
424 return null; | |
425 } | |
426 } | |
427 }, | |
399 files: { | 428 files: { |
400 value: {} | 429 value: {} |
401 }, | 430 }, |
402 full_name: { | 431 full_name: { |
403 /** | 432 /** |
404 * Generate the full name of the charm from its attributes. | 433 * Generate the full name of the charm from its attributes. |
405 * | 434 * |
406 * @method full_name.getter | 435 * @method full_name.getter |
407 * | 436 * |
408 */ | 437 */ |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
607 ATTRS: {} | 636 ATTRS: {} |
608 }); | 637 }); |
609 | 638 |
610 }, '0.1.0', { | 639 }, '0.1.0', { |
611 requires: [ | 640 requires: [ |
612 'model', | 641 'model', |
613 'model-list', | 642 'model-list', |
614 'juju-charm-id' | 643 'juju-charm-id' |
615 ] | 644 ] |
616 }); | 645 }); |
OLD | NEW |