add avatar icon for test user

This commit is contained in:
or-else
2019-01-13 11:22:15 +03:00
parent 4caff2b9f6
commit d1343acb9b
4 changed files with 14 additions and 9 deletions

View File

@ -60,6 +60,7 @@ If multiple `login-XYZ` are provided, `login-cookie` is considered first, then `
Type `<command> -h` for help Type `<command> -h` for help
See example at [sample-script.txt](sample-script.txt).
## Connecting to secure (HTTPS) server ## Connecting to secure (HTTPS) server

View File

@ -1,16 +1,20 @@
# This script creates a new user Test, uses fnd to locate user Alice, # This script creates a new user Test User, uses fnd to locate user Alice,
# subscribes to Alice, sends typing notification, sends a message, deletes user Test. # subscribes Test User to Alice, sends typing notification, sends a message,
# deletes user Test.
# Register new account # Create user 'Test User'
#.must $user acc --scheme=basic --secret=test:test123 \ #.must $user acc --scheme=basic --secret=test:test123 \
# --fn='Test User' --tags=test,test-user --do-login --cred=email:test@example.com # --fn='Test User' --photo=./test-128.jpg --tags=test,test-user --do-login \
# --auth=JRWPA --anon=JW \
# --cred=email:test@example.com
.must $user login bob:bob123 .must $user login bob:bob123
# .log $user # Print out user's auth token.
.log $user.params.token
# Login with a dummy credentials response # Login and confirm credentials with a dummy response
# .must login --scheme=token --secret=$user.params.token --cred=email::123456 # .must login --scheme=token --secret=$user.params.token --cred=email::123456
# Find Alice # Find Alice
@ -18,7 +22,8 @@
.must set fnd --public=email:alice@example.com .must set fnd --public=email:alice@example.com
.must $meta get fnd --sub .must $meta get fnd --sub
# .log $meta # Print out Alice's UID.
.log $meta.sub[0].user_id
# Subscribe to Alice # Subscribe to Alice
.must sub $meta.sub[0].user_id .must sub $meta.sub[0].user_id
@ -29,5 +34,5 @@ note $meta.sub[0].user_id
# Send message to Alice (async) # Send message to Alice (async)
pub $meta.sub[0].user_id 'Hello, Alice' pub $meta.sub[0].user_id 'Hello, Alice'
# Delete current user # Clean up: delete Test user
# .await del user --hard # .await del user --hard

BIN
tn-cli/test-128.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

View File

@ -192,7 +192,6 @@ def stdin(InputQueue):
except Exception as ex: except Exception as ex:
printerr("Exception in stdin", ex) printerr("Exception in stdin", ex)
print("stdin exited")
InputQueue.put("exit") InputQueue.put("exit")
# encode_to_bytes takes an object/dictionary and converts it to json-formatted byte array. # encode_to_bytes takes an object/dictionary and converts it to json-formatted byte array.