Opened 10 years ago

Closed 10 years ago

#55 closed (fixed)

WrongRspecType for manifest and advertisment RSpecs for AM API tests

Reported by: lnevers@bbn.com Owned by: somebody
Priority: major Milestone:
Component: AM Version: SPIRAL4
Keywords: AM API Cc:
Dependencies:

Description

Running the AM API Acceptance tests fails as follows:

$ ./am_api_accept.py -a am-undertest -V 2
F.F....F..FF.
======================================================================
FAIL: test_CreateSliver: Passes if the sliver creation workflow succeeds.  Use --rspec-file to replace the default request RSpec.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 625, in test_CreateSliver
    self.subtest_CreateSliverWorkflow()
  File "./am_api_accept.py", line 660, in subtest_CreateSliverWorkflow
    self.assertRspecType( manifest, 'manifest')
  File "/home/lnevers/gcf-1.6.2-rc3/src/omni_unittest.py", line 174, in assertRspecType
    raise WrongRspecType, msg
WrongRspecType: RSpec expected to have type 'manifest' but schema was not correct.

======================================================================
FAIL: test_CreateSliverWorkflow_multiSlice: Do CreateSliver workflow with multiple slices and ensure can not do ListResources on slices with the wrong credential.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 936, in test_CreateSliverWorkflow_multiSlice
    self.assertRspecType( "".join(manifest[i]), 'manifest')
  File "/home/lnevers/gcf-1.6.2-rc3/src/omni_unittest.py", line 174, in assertRspecType
    raise WrongRspecType, msg
WrongRspecType: RSpec expected to have type 'manifest' but schema was not correct.

======================================================================
FAIL: test_ListResources: Passes if 'ListResources' returns an advertisement RSpec.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 328, in test_ListResources
    self.subtest_ListResources()
  File "./am_api_accept.py", line 607, in subtest_ListResources
    self.assertRspecType( rspec, 'advertisement', typeOnly=typeOnly)
  File "/home/lnevers/gcf-1.6.2-rc3/src/omni_unittest.py", line 174, in assertRspecType
    raise WrongRspecType, msg
WrongRspecType: RSpec expected to have type 'advertisement' but schema was not correct.

======================================================================
FAIL: test_ListResources_geni_available: Passes if 'ListResources' returns an advertisement RSpec.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 342, in test_ListResources_geni_available
    self.subtest_ListResources()
  File "./am_api_accept.py", line 607, in subtest_ListResources
    self.assertRspecType( rspec, 'advertisement', typeOnly=typeOnly)
  File "/home/lnevers/gcf-1.6.2-rc3/src/omni_unittest.py", line 174, in assertRspecType
    raise WrongRspecType, msg
WrongRspecType: RSpec expected to have type 'advertisement' but schema was not correct.

======================================================================
FAIL: test_ListResources_geni_compressed: Passes if 'ListResources' returns an advertisement RSpec.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 335, in test_ListResources_geni_compressed
    self.subtest_ListResources()
  File "./am_api_accept.py", line 607, in subtest_ListResources
    self.assertRspecType( rspec, 'advertisement', typeOnly=typeOnly)
  File "/home/lnevers/gcf-1.6.2-rc3/src/omni_unittest.py", line 174, in assertRspecType
    raise WrongRspecType, msg
WrongRspecType: RSpec expected to have type 'advertisement' but schema was not correct.

----------------------------------------------------------------------
Ran 13 tests in 281.269s

FAILED (failures=5)

Manifest RSpecs contain the wrong schema name and URL. A sample Manifest from the test run:

<rspec type="manifest" xmlns="http://www.geni.net/resources/rspec/3" 
xmlns:ns2="http://hpn.east.isi.edu/rspec/ext/stitch/0.1/" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 
http://www.protogeni.net/resources/rspec/2/manifest.xsd 
http://hpn.east.isi.edu/rspec/ext/stitch/0.1/ 
http://hpn.east.isi.edu/rspec/ext/stitch/0.1/stitch-schema.xsd">  

There are no Advertisement rspec type returned only type "manifest" even when expecting advertisement.

Change History (5)

comment:1 Changed 10 years ago by lnevers@bbn.com

An Advertisement RSpec now show:

<rspec type="advertisement" xmlns="http://www.geni.net/resources/rspec/3" 
                xmlns:ns2="http://hpn.east.isi.edu/rspec/ext/stitch/0.1/" 
                xmlns:ns3="http://www.protogeni.net/resources/rspec/ext/emulab/1" 
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 
                                    http://www.protogeni.net/resources/rspec/2/ad.xsd 
                 http://hpn.east.isi.edu/rspec/ext/stitch/0.1/ 
                 http://hpn.east.isi.edu/rspec/ext/stitch/0.1/stitch-schema.xsd">  

The xsi:schemaLocation should be:

               xsi:schemaLocation="http://www.geni.net/resources/rspec/3 
                             http://www.geni.net/resources/rspec/3/ad.xsd 

comment:2 Changed 10 years ago by chaos@bbn.com

My nagios-based checks think the xsi:schemaLocation issue has been resolved now. Luisa, how does it look to you?

comment:3 Changed 10 years ago by lnevers@bbn.com

I see that the Advertisment rspec is now right. I still need to check the manifest RSpec.

comment:4 Changed 10 years ago by lnevers@bbn.com

Verified that manifest now includes correct schema location details. Re-running GENI AM API acceptance tests.

comment:5 Changed 10 years ago by lnevers@bbn.com

Resolution: fixed
Status: newclosed

The GENI AM API Acceptance test now fail with the problem capture in http://groups.geni.net/exogeni/ticket/15. Closing this ticket.

$ ./am_api_accept.py -V 2 -a  am-undertest
F.

F..........
======================================================================
FAIL: test_CreateSliver: Passes if the sliver creation workflow succeeds.  Use --rspec-file to replace the default request RSpec.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 612, in test_CreateSliver
    self.subtest_CreateSliverWorkflow()
  File "./am_api_accept.py", line 678, in subtest_CreateSliverWorkflow
    "but did not." % slicename)
  File "/home/lnevers/gcf-1.6.2/src/omni_unittest.py", line 154, in assertCompIDsEqual
    raise NotEqualComponentIDsError, msg
NotEqualComponentIDsError: Request RSpec and Manifest RSpec returned by 'ListResources' on slice 'acclne-183615' expected to have same component_ids but did not.

======================================================================
FAIL: test_CreateSliverWorkflow_multiSlice: Do CreateSliver workflow with multiple slices and ensure can not do ListResources on slices with the wrong credential.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./am_api_accept.py", line 970, in test_CreateSliverWorkflow_multiSlice
    "but did not." % slicenames[i])
  File "/home/lnevers/gcf-1.6.2/src/omni_unittest.py", line 154, in assertCompIDsEqual
    raise NotEqualComponentIDsError, msg
NotEqualComponentIDsError: Request RSpec and Manifest RSpec returned by 'ListResources' on slice 'acclne-1837160' expected to have same component_ids but did not.

----------------------------------------------------------------------
Ran 13 tests in 919.723s

FAILED (failures=2)
Note: See TracTickets for help on using tickets.