Agree with Rodric and his approach. The Runtime repos. should server to be better standalone homes for their own testcases/examples which we can further advantage in providing teaching examples. Priti and I are now looking at creating a template README for all the runtime repos. (and maybe others) to improve our docs/links from our .org website into something we can really advantage with developers (as they jump off from there). Currently, the READMEs are all quite different in assumption of role/reason a developer might go there and most are not typically great for the most important role "Action developer"; we need to consider this role when authoring and will do so in any template proposal.
-mr On 2018/07/23 16:54:44, Rodric Rabbah <[email protected]> wrote: > I vaguely recall it but I can't find the PR, in any case, here's the > rationale for moving the tests to their respective runtime. > > The openwhisk core (specifically, the invoker protocol) is not language > specific. So while we've had many tests for different languages in the > openwhisk repo, we didn't have consistent test suites, there was lots of > clone and own, and too many touch points for adding a new language runtime. > > In recent PRs and housekeeping, we've removed all the runtime specific > tests (REST, wsk CLI, and runtime tests) from the openwhisk repo. Instead, > there's a canonical test suite that aims to enforce some uniformity between > the various runtimes ("unit tests" against the runtime proxy), and a sniff > test as part of the system package that invokes a standard action for each > of the runtimes listed in the manifest. This reduces the touch points in > the openwhisk repo for a new runtime, and localizes all the runtime work to > its own repo and its maintainers. > > I've updated several of the runtimes to inherit this test suite and can > send a PR for the go runtime to do the same. In this way, these tests would > belong in the new go runtime proxy: > tests/src/test/scala/actionContainers/ActionLoopContainerTests.scala > tests/src/test/scala/actionContainers/ActionLoopGoContainerTests.scala > tests/src/test/scala/actionContainers/ActionLoopSwiftContainerTests.scala > > since they're testing the functionality of the proxy. If you've got these > tests covered by go unit tests, then we don't need duplicate tests, I'd say. > > The dependence on the openwhisk repo for the test harness is managed > through a snapshot build for now (for local development, thanks to Chetan), > and this is how we've set up Travis too. > > -r > > > > On Mon, Jul 23, 2018 at 4:28 PM, Michele Sciabarra <[email protected]> > wrote: > > > You closed the PR (I have the email somewhere) with a comment "move in the > > runtime" and I removed the repo as it was only holding that change. > > > > I just pushed again the code on github. It is here: > > > > https://github.com/sciabarracom/incubator-openwhisk > > > > I do not think it is mergeable with the current repo. > > > > The significant files are just: > > > > tests/src/test/scala/actionContainers/ActionLoopContainerTests.scala > > tests/src/test/scala/actionContainers/ActionLoopGoContainerTests.scala > > tests/src/test/scala/actionContainers/ActionLoopSwiftContainerTests.scala > > tests/src/test/scala/actionContainers/ResourceHelpers.scala > > > > However, since I was requested to move in the repo, I fixed my original, > > "cram based" test. > > > > https://github.com/apache/incubator-openwhisk-runtime-go/pull/43 > > > > I do not really see a good fit to add a lot of scala code to a go repo > > just to run a bunch of simple tests while I already have those tests > > running with Cram (https://pypi.org/project/cram/). Those are really > > just integration tests. > > > > Most of the tests are actually already rewritten in Go and integrated in > > the travis build (it was hard enough as the timing in Travis are different > > than on a mac). > > > > -- > > Michele Sciabarra > > [email protected] > > > > ----- Original message ----- > > From: Rodric Rabbah <[email protected]> > > To: [email protected] > > Subject: Re: Where to contribute examples for Golang? > > Date: Mon, 23 Jul 2018 15:53:28 +0000 > > > > > I contributed ScalaTest tests for my runtime to the main repository, as > > it was requested, and my PR was closed because now they should be moved ... > > in the runtime. > > > > Do you have a link for the PR? This query doesn't return anything > > https://github.com/apache/incubator-openwhisk/pulls? > > utf8=%E2%9C%93&q=is%3Apr+from%3Asciabarra > > maybe I have your github id wrong. I'm happy to take a look and help. > > > > -r > > >
