Fixed association facets.

The association config has been removed because it incorrectly assumes there is only one association between two entities. Now each association is defined separately using association facets.

The service.py has been modified to specify the correct relationships. The API.txt has been updated.

https://fedorahosted.org/freeipa/ticket/960
This commit is contained in:
Endi S. Dewata
2011-02-11 18:04:04 -06:00
committed by Adam Young
parent 1e9f923c49
commit eb8f091c9b
19 changed files with 189 additions and 262 deletions

View File

@@ -23,7 +23,7 @@ module('associate');
test("Testing serial_associator().", function() {
expect(10);
expect(7);
var orig_ipa_cmd = IPA.cmd;
@@ -42,15 +42,10 @@ test("Testing serial_associator().", function() {
counter++;
equals(
name, params.method,
name, params.other_entity+'_'+params.method,
"Checking IPA.cmd() parameter: method"
);
equals(
objname, params.other_entity,
"Checking IPA.cmd() parameter: object name"
);
equals(
args[0], "user"+counter,
"Checking IPA.cmd() parameter: primary key"
@@ -65,7 +60,7 @@ test("Testing serial_associator().", function() {
ok(true, "on_success() is invoked.");
};
var associator = serial_associator(params);
var associator = IPA.serial_associator(params);
associator.execute();
IPA.cmd = orig_ipa_cmd;
@@ -73,7 +68,7 @@ test("Testing serial_associator().", function() {
test("Testing bulk_associator().", function() {
expect(5);
expect(4);
var orig_ipa_cmd = IPA.cmd;
@@ -92,15 +87,10 @@ test("Testing bulk_associator().", function() {
counter++;
equals(
name, params.method,
name, params.entity_name+'_'+params.method,
"Checking IPA.cmd() parameter: method"
);
equals(
objname, params.entity_name,
"Checking IPA.cmd() parameter: object name"
);
equals(
args[0], params.pkey,
"Checking IPA.cmd() parameter: primary key"
@@ -120,7 +110,7 @@ test("Testing bulk_associator().", function() {
ok(true, "on_success() is invoked.");
};
var associator = bulk_associator(params);
var associator = IPA.bulk_associator(params);
associator.execute();
IPA.cmd = orig_ipa_cmd;