• Home
  • History
  • Annotate
  • only in /external/autotest/client/common_lib/cros/fake_device_server/client_lib/
History log of /external/autotest/client/common_lib/cros/fake_device_server/client_lib/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
735fec04a0041878cddd4877433414f528fac68d 16-Aug-2015 Vitaly Buka <vitalybuka@chromium.org> libweave: Remove device_kind and embedded_code_path

Keep only embedded_code, implementation will decide how to get it.
device_kind is not supported by server already.

BUG=brillo:1257
TEST=`FEATURES=test emerge-gizmo libweave buffet`
`test_that -b $BOARD $DEV_HOST e:buffet_.*`

Change-Id: I3ed09c8e879db4c0c5737b523d3b16cd31360619
Reviewed-on: https://chromium-review.googlesource.com/293940
Reviewed-by: Vitaly Buka <vitalybuka@chromium.org>
Commit-Queue: Vitaly Buka <vitalybuka@chromium.org>
Tested-by: Vitaly Buka <vitalybuka@chromium.org>
evices.py
egistration.py
57020c094a377700b0ad4d558d70062a19f1370a 23-Mar-2015 Christopher Wiley <wiley@chromium.org> autotest: Confirm that fake GCD servers have started.

BUG=brillo:641
TEST=One class of errors, where we get bad responses from the server
on startup, no longer happens in 50 runs of buffet_Registration.

Change-Id: Ia9a80cfe9bfea3bb5856dc983a5053dd6d710aa9
Reviewed-on: https://chromium-review.googlesource.com/261806
Reviewed-by: David Zeuthen <zeuthen@chromium.org>
Tested-by: Christopher Wiley <wiley@chromium.org>
Commit-Queue: Christopher Wiley <wiley@chromium.org>
ommon_client.py
eta.py
e24dba0976c3e97df4640c6b89502a430cc91ebb 19-Mar-2015 David Zeuthen <zeuthen@chromium.org> buffet: Check that buffet reconnects in case the server return an error.

We do this by making fake_device_server return HTTP Error 500 and then
check that buffet reverts to the CONNECTING state. Then we stop
failing requests and check that buffet reverts to CONNECTED. This is
intended to simulate the device losing connectivity to the server and
then reconnecting once connectivity has been restored.

TEST=buffet_Registration still passes.
BUG=brillo:593

Change-Id: I496120ad72d44c225c5a53dbf3bd92c437bdc8a8
Reviewed-on: https://chromium-review.googlesource.com/260842
Tested-by: David Zeuthen <zeuthen@chromium.org>
Reviewed-by: Vitaly Buka <vitalybuka@chromium.org>
Commit-Queue: David Zeuthen <zeuthen@chromium.org>
ail_control.py
624d9d162b6145c9a9931d82942c813bd5b3a921 04-Mar-2015 David Zeuthen <zeuthen@chromium.org> buffet: Check status is invalid_credentials if unable to obtain access_token.

Specifically, we only transition into this state if the server-side
returns the invalid_grant error. IOW, transient errors (e.g. missing
network connectivity) will not trigger this state (we could add a test
to verify this).

BUG=brillo:275
TEST=The brillo_Registration autotest passes.

Change-Id: Ieda1ac571702cd3a89bc623c16ca2e0930722590
Reviewed-on: https://chromium-review.googlesource.com/255881
Commit-Queue: David Zeuthen <zeuthen@chromium.org>
Tested-by: David Zeuthen <zeuthen@chromium.org>
Reviewed-by: David Zeuthen <zeuthen@chromium.org>
auth.py
28c4689b8f25a7ddbff3d1c84d5e675994877b41 03-Mar-2015 David Zeuthen <zeuthen@chromium.org> buffet: Check that buffet refreshes its access token if getting a 401.

We do this by requesting fake_device_server to mark the access token
used by buffet as invalid so requests from the device will error
out. This actually exposed a bug in buffet which is fixed in the
dependent CL.

Also rename fake_oauth.py to oauth.py to make room for a fake and use
that in unit-tests where needed.

BUG=brillo:275
TEST=The brillo_Registration autotest passes.
CQ-DEPEND=CL:255590

Change-Id: I0e7afeb9d1ff11fa0acbe52d88f7685021d5329c
Reviewed-on: https://chromium-review.googlesource.com/255480
Reviewed-by: Christopher Wiley <wiley@chromium.org>
Commit-Queue: David Zeuthen <zeuthen@chromium.org>
Tested-by: David Zeuthen <zeuthen@chromium.org>
auth.py
3c02dbac644d951bc264158d3f4efea577345b84 12-Feb-2015 Christopher Wiley <wiley@chromium.org> autotest: Support post Registration Buffet requests

Buffet tries to patch its device resource on startup, aborts
limbo commands, and then starts periodically polling for commands.

BUG=brillo:15
TEST=buffet_Registration passes with these changes after being
expanded to expect command polling to work.

Change-Id: I0e3cce44fdf088bf2d063a03ff07e5073624e03d
Reviewed-on: https://chromium-review.googlesource.com/249540
Tested-by: Christopher Wiley <wiley@chromium.org>
Reviewed-by: Alex Vakulenko <avakulenko@chromium.org>
Commit-Queue: Christopher Wiley <wiley@chromium.org>
ommands.py
0f333af62f6f39a9cdc1bd0521345cd3a39c29e3 09-Feb-2015 Christopher Wiley <wiley@chromium.org> buffet: Bring fake_device_server up to speed with registation flow

The actual registration flow has changed a little bit. In particular,
now the client POSTs to create a ticket, the device PATCHes it, and
then the device POSTs to finalize the ticket.

BUG=brillo:172
TEST=A test consuming these APIs passes.

Change-Id: Ifd1d1c6e4bbd23ef34062c12529eca1e36e66713
Reviewed-on: https://chromium-review.googlesource.com/247560
Reviewed-by: Christopher Wiley <wiley@chromium.org>
Commit-Queue: Christopher Wiley <wiley@chromium.org>
Tested-by: Christopher Wiley <wiley@chromium.org>
evices.py
egistration.py
feedba871f9ea080e3562f7d9875f09e63468c55 08-May-2014 Chris Sosa <sosa@chromium.org> Add auth support to client_lib and test to be able to use against the live server.

In this CL I've added various oauth helpers to convert codes to auth tokens
for use when interacting with our actual servers. In order to facilitate quick
testing I've modified this test script to either test against the fake
server OR the live server based on whether you pass in an auth code
to the command line (see usage).

There's still a couple issues (left as TODO's here) but this seems like
a good point for review.

BUG=chromium:361204
TEST=Tested up to command insertion with live server + fake server + unittests

Change-Id: Ic7166ddaa50d171dbf9a8cbb4b50b736f79a32b6
Reviewed-on: https://chromium-review.googlesource.com/198784
Tested-by: Chris Sosa <sosa@chromium.org>
Reviewed-by: Alex Vakulenko <avakulenko@chromium.org>
Reviewed-by: Christopher Wiley <wiley@chromium.org>
Commit-Queue: Chris Sosa <sosa@chromium.org>
lient_lib_test.py
ommands.py
ommon_client.py
evices.py
auth_helpers.py
egistration.py
12dd813c417478dffb4bf66994eebbb125db7a27 29-Apr-2014 Chris Sosa <sosa@chromium.org> Add a small Python client library to communicate with the buffet server.

This CL adds a small client library for interacting with the
fake_device_server. Currently it does not support the actual service
as I do not pass all the necessary HEADERS to auth needed (which I will
add later).

I've also added an integration test script that runs through all the common
client methods / server interactions for testing this library.

BUG=chromium:361204
TEST=Ran integration test.

Change-Id: Ieb0c4d594557fabbc3871f549e932c87f73afb05
Reviewed-on: https://chromium-review.googlesource.com/197430
Tested-by: Chris Sosa <sosa@chromium.org>
Reviewed-by: Alex Vakulenko <avakulenko@chromium.org>
Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
_init__.py
lient_lib_test.py
ommands.py
ommon.py
ommon_client.py
evices.py
egistration.py