forked from indymedia/epicyon
Fix test
parent
5ed5aa0d33
commit
d8126b4ffa
|
@ -505,7 +505,7 @@ if args.message:
|
|||
followersOnly=False
|
||||
print('Sending post to '+args.sendto)
|
||||
|
||||
sendPostViaServer(session,args.nickname,args.password, \
|
||||
sendPostViaServer(baseDir,session,args.nickname,args.password, \
|
||||
domain,port, \
|
||||
toNickname,toDomain,toPort,ccUrl, \
|
||||
httpPrefix,sendMessage,followersOnly, \
|
||||
|
|
4
posts.py
4
posts.py
|
@ -860,7 +860,7 @@ def sendPost(session,baseDir: str,nickname: str, domain: str, port: int, \
|
|||
thr.start()
|
||||
return 0
|
||||
|
||||
def sendPostViaServer(session,fromNickname: str,password: str, \
|
||||
def sendPostViaServer(baseDir,session,fromNickname: str,password: str, \
|
||||
fromDomain: str, fromPort: int, \
|
||||
toNickname: str, toDomain: str, toPort: int, cc: str, \
|
||||
httpPrefix: str, content: str, followersOnly: bool, \
|
||||
|
@ -923,7 +923,7 @@ def sendPostViaServer(session,fromNickname: str,password: str, \
|
|||
toDomainFull=toDomain+':'+str(toPort)
|
||||
toPersonId=httpPrefix+'://'+toDomainFull+'/users/'+toNickname
|
||||
postJsonObject = \
|
||||
createPostBase(None, \
|
||||
createPostBase(baseDir, \
|
||||
fromNickname,fromDomain,fromPort, \
|
||||
toPersonId,cc,httpPrefix,content, \
|
||||
followersOnly,saveToFile,clientToServer, \
|
||||
|
|
2
tests.py
2
tests.py
|
@ -1117,7 +1117,7 @@ def testClientToServer():
|
|||
assert len([name for name in os.listdir(outboxPath) if os.path.isfile(os.path.join(outboxPath, name))])==0
|
||||
assert len([name for name in os.listdir(inboxPath) if os.path.isfile(os.path.join(inboxPath, name))])==0
|
||||
sendResult= \
|
||||
sendPostViaServer(sessionAlice,'alice',password, \
|
||||
sendPostViaServer(aliceDir,sessionAlice,'alice',password, \
|
||||
aliceDomain,alicePort, \
|
||||
'bob',bobDomain,bobPort,None, \
|
||||
httpPrefix,'Sent from my ActivityPub client',followersOnly, \
|
||||
|
|
Loading…
Reference in New Issue