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

Adding mw.smw.ask to available smw functions #24

Merged
merged 2 commits into from
Dec 3, 2016

Conversation

oetterer
Copy link
Collaborator

@oetterer oetterer commented Nov 29, 2016

In reference to #11 I added 'ask' to the available lua functions. This PR also includes a section in the documentation about the differences between the ask and getQueryResult.

@oetterer oetterer changed the title Adding mw.smw.set to available smw functions Adding mw.smw.ask to available smw functions Nov 29, 2016
@oetterer oetterer mentioned this pull request Nov 29, 2016
11 tasks
@oetterer oetterer force-pushed the ask branch 8 times, most recently from 4cdf732 to 3954448 Compare November 30, 2016 10:06
@oetterer oetterer force-pushed the ask branch 9 times, most recently from b1cba09 to 41b262d Compare December 2, 2016 06:57
@mwjames
Copy link
Contributor

mwjames commented Dec 3, 2016

Requires a rebase after #23 has been merged.

@mwjames
Copy link
Contributor

mwjames commented Dec 3, 2016

Probably a matter of personal style but when creating a large dataProvider, I would go for individual providers because in case the test fails you would need to count/find the array entry and change the structure which may prove difficult in some situations.

$provider['Can explain the purpose'] = [

];

// or leave it and be assigned a number
$provider[] = [

];

return $provider;

Nothing that prevents it from merging.

@mwjames mwjames merged commit 4c3a4c0 into SemanticMediaWiki:master Dec 3, 2016
@mwjames
Copy link
Contributor

mwjames commented Dec 3, 2016

What happens when you use format=debug with the ask parameters? format=debug doesn't return a QueryResult object (returns a string).

@oetterer oetterer deleted the ask branch December 5, 2016 06:13
@oetterer
Copy link
Collaborator Author

oetterer commented Dec 5, 2016

Probably a matter of personal style but when creating a large dataProvider, I would go for individual providers because in case the test fails you would need to count/find the array entry and change the structure which may prove difficult in some situations.

Thanks for the suggestion. Was looking for a way to annotate tests. Will work this in, next time I touch the tests.

What happens when you use format=debug with the ask parameters? format=debug doesn't return a QueryResult object (returns a string).

Thank you very much for pointing this out. Did not know that. Put a PR (#26) online with a suggestion to handle this.

@mwjames
Copy link
Contributor

mwjames commented Dec 10, 2016

Thank you very much for pointing this out. Did not know that. Put a PR (#26) online with a suggestion to handle this.

I guessed that much hence my inquiry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants