Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Static API define behaviour before init and add test case #129

Merged

Conversation

seank-img
Copy link
Contributor

No description provided.

@seank-img seank-img added the bug label May 3, 2016
@seank-img seank-img added this to the 0.1.8 milestone May 3, 2016
@seank-img
Copy link
Contributor Author

[valgrind]

@@ -34,7 +34,19 @@ TEST_F(TestStaticClientHandler, AwaStaticClient_SetResourceOperationHandler_Inva
{
auto client = AwaStaticClient_New();
ASSERT_TRUE(client != NULL);
EXPECT_EQ(AwaError_Success, AwaStaticClient_DefineObject(client, 9999, "TestObject", 0, 1));

EXPECT_EQ(AwaError_DefinitionInvalid, AwaStaticClient_SetResourceOperationHandler(client, 9999, 1, handler));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps it would be better to create a new error code, suggest AwaError_StaticClientNotInitialized? Then users know that their calls are failing because of that reason.

@seank-img seank-img force-pushed the static-api-fixes branch from 561e9cd to 26a7d74 Compare May 3, 2016 22:59
@seank-img seank-img force-pushed the static-api-fixes branch from 26a7d74 to b5b353b Compare May 3, 2016 23:20
@DavidAntliff DavidAntliff merged commit 14a0e2f into ConnectivityFoundry:master May 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants