Thursday, 2016-11-10

*** yuntongjin has joined #openstack-nimble01:45
*** lei-zh has joined #openstack-nimble01:51
zhenguoliusheng, yuntongjin, lei-zh: shaohe_feng is absent today, we have added db,object base test case yesterday and the API test is already under review.  But seems like the tests work is more than we expected at the meeting. After discussing with shaohe, he suggested that everyone should assign more db tests to himself to make sure we can finish the task by02:43
zhenguothis week, the example test case is already there, it should not be very hard to add more, thank you all.02:43
zhenguoyuntongjin, lei-zh: added Zhong Luyao, seems he is not in our irc channel :(02:45
zhenguos/he/she02:46
lei-zhok, I'll add here03:06
zhenguolei-zh: thanks03:06
openstackgerritMerged openstack/nimble: Add base API tests and utils  https://review.openstack.org/39568803:24
openstackgerritMerged openstack/nimble: change the type of extra to JsonEncodedDict  https://review.openstack.org/39550803:24
liushengzhenguo: the tests based on db are unit tests ? I may prefer functional tests :P03:28
zhenguoliusheng: yes, you can focus on functional tests03:29
zhenguoliusheng: but all functional tests :P03:29
liushengzhenguo: but I found the change https://review.openstack.org/#/c/395688/1 has added the tests based on db back to tests/unit/ which I moved to tests/functional/03:31
liushengand there are some "print()" statements in nimble/tests/unit/api/base.py :(03:32
zhenguoliusheng: oh sorry, I don't notice that, let me check03:32
zhenguoliusheng: oh, yes it's duplicate :(03:35
liushengaddtionally, our functional tests are based on sqlite, do we need a real mysql backend ? I don't know the difference between sqlite and mysql, we can only face sqlalchemy :)03:37
zhenguoliusheng: seems sqlite is fine which is more lightweight thant mysql03:38
liushengzhenguo: yes, it is convenient for testing03:39
zhenguoliusheng: do we still need api tests in unit?03:39
*** yuntongjin has quit IRC03:40
liushengzhenguo: I think we are testing real api request, so they are functal tests, am I right  ?03:40
zhenguoliusheng:  yes, I think so03:40
liushengI think the unit test for api can be added only when the functional test cannot cover03:43
zhenguoliusheng: ok, so we can just keep functional tests now, will remove the duplicate part.03:44
liushengzhenguo: ok03:45
*** luyao has joined #openstack-nimble03:47
lei-zhwelcome luyao:)03:47
*** yuntongjin has joined #openstack-nimble03:49
luyao大家好:)03:49
*** yuntongjin has quit IRC03:51
openstackgerritZhenguo Niu proposed openstack/nimble: Revert "Add base API tests and utils"  https://review.openstack.org/39592603:55
zhenguoluyao: welcome!03:56
liushengluyao: welcome!03:56
* zhenguo is away for lunch...03:56
*** lei-zh has quit IRC04:18
*** yuntongjin has joined #openstack-nimble04:49
*** luyao has quit IRC05:26
*** shaohe_feng has quit IRC05:35
*** shaohe_feng has joined #openstack-nimble05:36
*** lei-zh has joined #openstack-nimble05:58
*** luyao has joined #openstack-nimble06:04
openstackgerritMerged openstack/nimble: Revert "Add base API tests and utils"  https://review.openstack.org/39592606:06
RuiChenluyao: \o/06:30
openstackgerrityuntongjin proposed openstack/nimble: Add unittest test_filter_scheduler  https://review.openstack.org/38781406:32
zhenguoliusheng, RuiChen, yuntongjin, lei-zh, luyao: do you have some concerns about using really db for objects tests instead of mock db calls?  https://review.openstack.org/#/c/395610/06:32
zhenguoit's time consuming but can cover really db calls, or db tests cases have already guaranteed it.06:35
zhenguoand Kevin_Zheng :)06:39
*** luyao has quit IRC06:43
liushenglooks the tests in Nova, the objects' related tests are located in tests/unit/ and db calls mocked. the tests of real db calls are in tests/functional06:43
zhenguoliusheng: yes, other projects all use mock db calls...06:45
liushengI am not concern with time consuming06:48
liushengbut may they are a bit duplicated  ? :)06:48
zhenguothe purpuse of that patch is to cover the db column type not consistent with object field type as we find a bug for our instance.extra field, seems when we have enough functional tests, that should be covered, and we don't need really db calls?06:48
zhenguoliusheng: lol, yes seems duplicated06:49
zhenguoliusheng:Ithink we can hold on that patch and wait for shaohe_feng back to office.06:50
liushengzhenguo: sure :)06:51
liushengzhenguo: about the functional tests of instance CURD, do you think it is ok to mock the RPC call to nimble-engine ?06:54
zhenguoliusheng: not sure, but as we already setup the whole env with devstack for functional, it should be really call tests or that should be tempest things?06:56
liushengzhenguo:hmm, so the functioan tests can cover api->engine->ironic, tbh, I also not sure about this should be in tempest :)06:58
zhenguoliusheng: maybe mocked ironic,neutron,glance calls, but not for engine calls?06:59
RuiChenwe are talking about unit tests?07:00
zhenguoRuiChen: yes, unit tests and functional tests07:00
liushengRuiChen: about unit tests and instance CURD functional tests07:01
liushengzhenguo: make sense to me07:01
RuiChenI think we should mock db call in UT, but not in functional test07:01
zhenguoand I'm confused about tempest and functional tests, does tempest already covered functional tests things?07:02
RuiChenyeah, I have the same question about the difference between tempest and functional07:03
*** luyao has joined #openstack-nimble07:03
*** luyao has left #openstack-nimble07:06
*** luyao has joined #openstack-nimble07:06
liushengmay tempest if for a whole process with real backends and configs ? and functional tests if for a sub-process, and UT is for a method ? personal thoughts07:06
RuiChenzhenguo: how to add gerritbot for nimbleclient? seems we lack the notify from client project07:06
zhenguoRuiChen: add nimbleclient under nimble https://review.openstack.org/#/c/385786/2/gerritbot/channels.yaml07:09
zhenguoliusheng: seems correct07:09
RuiChenthanks zhenguo, I commit a patch to add it.07:10
zhenguoRuiChen: thanks :)07:10
*** lei-zh has quit IRC07:11
RuiChenliusheng: zhenguo I'm not sure what's means about sub-process in functional tests, part of test cases of tempest?07:12
zhenguoRuiChen: I just check Ironic functional tests dir, it's empty... and api tests are all in unit dir07:13
RuiChenhmmm, I have no idea about it, might we can check Nova, Neutron or Cinder?07:15
zhenguoRuiChen, liusheng: I find the ironic functional job defination with a comment 'No post_test_hook is needed while tests live in tempest'07:15
zhenguoreally confused07:15
liushenghttp://stackoverflow.com/questions/3670729/what-is-the-difference-between-integration-testing-and-functional-testing07:15
liushengthat is the difference between functional tests and  intergration tests07:16
*** lei-zh has joined #openstack-nimble07:16
RuiChen^^ make sense07:16
zhenguoit's clear07:18
zhenguoliusheng: so just like we discussed, fuctional tests should cover really calls of nimble and mock calls for ironic, neutron, glance, right?07:19
liushengthere is an auto-scalling test in Ceilometer's tempest :)07:19
openstackgerrityuntongjin proposed openstack/nimble: Add unittest test_node_filters for scheduler  https://review.openstack.org/39598507:20
liushengzhenguo: seems like, but in other words, the ironic is a part of nimble's funtionality, right ?07:21
liushengzhenguo: also confused ..07:22
zhenguoliusheng, RuiChen: we can assume ironic works,07:22
liushengso let07:23
zhenguoliusheng: we can assume all other services work, only tests nimble logic, from api to object then to really db07:23
liushengso let's mock ironic ? hah07:23
zhenguoliusheng: yes, just gurantee ourself ok07:23
zhenguoliusheng: but I still believe tempest can cover all cases07:24
zhenguoliusheng: but currently I think it's ok to use functional tests like we discussed07:24
RuiChenliusheng: nimble-specs project had been added in infra? I can add the gerritbot for it in my patch07:24
liushengRuiChen: no +2 and +A for now :(07:25
RuiChenno worried, lots of core in vacation, hah07:26
RuiChenso i only add nimbleclient in my patch, any update, please ping me07:26
liushengzhenguo: so I will try to add functional tests of instance CURD07:27
zhenguoliusheng, RuiChen: ok, we can update the patch for specs to be added to gerritbot itself07:27
zhenguoliusheng: thanks, tempest should be considerd after we are public07:27
liushengzhenguo: ok07:28
liushengzhenguo: seems your reverted patch use a real token authentication for api tests, but I skipped the token authentication previously, may because I am lazy :P07:34
zhenguoliusheng: haha07:35
RuiChenzhenguo and liusheng, add you into a review list https://review.openstack.org/#/c/395989/ gerritbot07:35
zhenguoRuiChen: ok07:35
zhenguoliusheng: for ACL tests we need real token07:36
liushengzhenguo: yeah, but I added "'acl_public_routes': ['/', '/v1/.*']" in nimble.tests.functional.api.BaseApiTest#_make_app which skip the token auth07:37
liushengzhenguo: so should I stole your code and add it now ?07:37
zhenguoliusheng: seems not needed now,07:38
zhenguoliusheng: but does functional tests cover cases that non admin users forbbiden to do things like admin or other policies07:38
liushengthat seems related with RBCA than ACL, but we may also need tests for ACL ...07:43
zhenguoliusheng: yes, should that be in functional or unit tests?07:44
liushengzhenguo: in funtional07:46
zhenguoliusheng: ok07:47
*** openstackgerrit has quit IRC07:48
*** openstackgerrit has joined #openstack-nimble07:49
*** yuntongjin has quit IRC08:11
*** yuntongjin has joined #openstack-nimble08:21
*** luyao has quit IRC08:22
openstackgerritZhenguo Niu proposed openstack/nimble: Add extra field to instance API  https://review.openstack.org/39603409:12
zhenguoliusheng: I added 'extra' field to instance API, maybe will affect the functional tests you are working on09:14
liushengzhenguo: thanks for reminding me09:14
zhenguoliusheng: hah09:15
zhenguoRuiChen: seems hanzhang is absent, I added an extra field to instance API, client needs to be updated accordingly09:27
openstackgerritShaoHe Feng proposed openstack/nimble: use really DB for instance object test  https://review.openstack.org/39561009:30
shaohe_fengzhenguo: I'm back09:31
zhenguoshaohe_feng: regarding the really db calls, we discussed about it this afternoon09:32
zhenguoshaohe_feng: seems it's somewhat duplicate09:32
zhenguoshaohe_feng: oh, forget to say "welcome back..." sorry :P09:33
*** shihanzhang has joined #openstack-nimble09:35
RuiChenzhenguo: shihanzhang disconnect from irc channel, he will be back soon.09:35
zhenguoRuiChen: ok, got it, thanks09:35
zhenguoshaohe_feng: you can scroll back to see the history, as the object and db types inconsistent is because we don't really use the field and there's no functional tests cover it09:36
shihanzhanghi all, i am online09:36
zhenguoshiahnzhang: hi, I updated the instance API to add a new filed extra09:37
shihanzhangdo i need to modify the nimble client?09:38
zhenguoshihanzhang: yes, need to add a new option when creating instance09:38
zhenguoshihanzhang: like metadata or extra09:38
shihanzhangok, i will check it latter09:38
zhenguoshihanzhang: thanks09:39
shihanzhangnp09:39
*** luyao has joined #openstack-nimble09:39
*** luyao has left #openstack-nimble09:39
*** luyao has joined #openstack-nimble09:39
shaohe_fengzhenguo: Got it. then we still need mock DB.09:45
zhenguoshaohe_feng: yes, thanks09:46
shaohe_fengzhenguo: And we really need functional test cover ervery thing. That is hard.09:46
zhenguoshaohe_feng: yes, and I have abandon the api tests patch in unit tests, it's duplicate with functional09:47
shaohe_fengzhenguo: Actually, the test case and the our application code should be  parallel09:47
zhenguoshaohe_feng: only functional tests have really db calls, it can test with the really env09:48
shaohe_fengzhenguo: the commerce product do well than open source for test case.09:48
zhenguoshaohe_feng: sure,09:49
shaohe_fengzhenguo: For the commerce company hire a lot of testers for their product.09:49
*** yuntongjin has quit IRC09:50
zhenguoshaohe_feng: sorry, I have to be away for dinner, will be back in about 1h,09:50
* zhenguo away09:50
zhenguoshaohe_feng: ttyl09:51
*** luyao has quit IRC10:01
openstackgerritMerged openstack/nimble: Use sqlalchemyutils.model_query  https://review.openstack.org/39177310:05
*** lei-zh has quit IRC10:07
openstackgerritliusheng proposed openstack/nimble: Clean some redundant default log levels settings  https://review.openstack.org/39608310:31
*** liusheng has quit IRC10:44
openstackgerritShaoHe Feng proposed openstack/nimble: Add project filtering for instance api  https://review.openstack.org/38956210:49
*** liusheng has joined #openstack-nimble11:26
openstackgerritZhenguo Niu proposed openstack/nimble: Add db instance_type base test case  https://review.openstack.org/39613611:49
openstackgerritMerged openstack/nimble: Clean some redundant default log levels settings  https://review.openstack.org/39608312:12
openstackgerritMerged openstack/nimble: Add extra field to instance API  https://review.openstack.org/39603412:12
*** shihanzhang has quit IRC12:17
*** shihanzhang has joined #openstack-nimble12:19
openstackgerritShaoHe Feng proposed openstack/nimble: missing comma in samples json file, add it  https://review.openstack.org/39616412:25
openstackgerritMerged openstack/nimble: Add project filtering for instance api  https://review.openstack.org/38956212:27
openstackgerritMerged openstack/nimble: missing comma in samples json file, add it  https://review.openstack.org/39616412:54
*** RuiChen has quit IRC13:26
*** Kevin_Zheng has quit IRC13:26
*** RuiChen has joined #openstack-nimble13:26
*** Kevin_Zheng has joined #openstack-nimble13:28
*** lei-zh has joined #openstack-nimble14:53
*** lei-zh has quit IRC15:58
*** openstackgerrit has quit IRC19:48
*** openstackgerrit has joined #openstack-nimble19:49

Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!