Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Commits on Source (233)
66c6b6e0
(feat) enabling disabling comments in posts
Jul 10, 2019
eb0d1883
(feat) disable comments on blogs
Jul 11, 2019
9e90af8f
(feat) add endpoint request for disabling comments
Jul 11, 2019
4a4cafd4
(fix) add showerror method to blogs view
Jul 11, 2019
429ab71d
(fix) update test snapshots
Jul 15, 2019
d3e37b67
(feat) ability to disable group conversations
Jul 16, 2019
bd1236c8
(fix) vertical align 'more' button
Jul 16, 2019
9c52372f
Merge branch 'master' into 'sprint/InterestingIguana.feat.enable.disable.comments'
Jul 18, 2019
17b82918
(fix) error tap to reload in boostfeed
Jul 24, 2019
4d108f20
(fix) no subs count on channels
Jul 24, 2019
3c713ae9
(feat) use entities service in activity screen
Jul 24, 2019
f5fe7c80
(feat) add feature flag to enable disable comments functionality
Jul 24, 2019
0dc4185f
Merge branch 'sprint/InterestingIguana.feat.enable.disable.comments' of...
Jul 24, 2019
497fe6e3
(feat) refresh wallet when user open tab
Jul 25, 2019
ef113722
(fix) add spacing to be on a par with standard
Jul 25, 2019
8cad9689
(feat) refresh wallet data when user open the tab
Jul 25, 2019
8d751047
(feat) default false for feature flags
Jul 25, 2019
491dc30d
(chore) fix spec test
Jul 25, 2019
0e36dd35
(feat) put group conversation disabling behind a feature flag
Jul 26, 2019
3a0981e8
Merge branch 'sprint/JollyJellyfish.feat.group-conv.feature-flag' into...
Jul 26, 2019
a887136b
(fix) groups bar cache not updating
Jul 26, 2019
b30d2bb3
(chore) update blogFaker
Jul 26, 2019
a742a323
(chore) fields added to users faker
Jul 26, 2019
bc2b82b7
(feat) reimplement boost injector for offline first
Jul 26, 2019
a159ee35
(fix) post prepend cause repeating posts in feed
Jul 29, 2019
f85cdc5e
(feat) mock boosted content service
Jul 29, 2019
3b57427b
(chore) fix failing tests
Jul 29, 2019
fb5afb2e
(fix) boosted content service logic
Jul 29, 2019
872416f1
(feat) spec test boosted content service
Jul 29, 2019
83b8ab75
(fix) channel feed prepend
Jul 29, 2019
410fa5ee
(fix) discovery errors changing tabs
Jul 30, 2019
31cc7747
(chore) fix spacing
Jul 30, 2019
50224020
Merge branch 'sprint/JollyJellyfish.bug.post.prepend.broke.feed' into 'release/3.8.0'
Jul 30, 2019
a8c34bec
Merge branch 'sprint/JollyJellyfish.bug.should.prepend.post.mychannel' into 'release/3.8.0'
Jul 30, 2019
531ddfb7
Merge branch 'sprint/JollyJellyfish.fix.groups-bar.cache.not.updating' into 'release/3.8.0'
Jul 30, 2019
bdee987c
Merge branch 'sprint/JollyJellyfish.feat.default.false.feature-flag' into 'release/3.8.0'
Jul 30, 2019
db9e9e22
Merge branch...
Jul 30, 2019
6430f944
Merge branch 'sprint/JollyJellyfish.fix.no.subs-count.in.channels' into 'release/3.8.0'
Jul 30, 2019
2c0c502b
Merge branch 'sprint/JollyJellyfish.fix.tap.tab.reload.boostfeed' into 'release/3.8.0'
Jul 30, 2019
a7c27e69
Merge branch 'feat/fix-discovery-tabs-change-errors' into 'release/3.8.0'
Jul 30, 2019
dc43db7e
Merge remote-tracking branch 'upstream/release/3.8.0' into...
Jul 30, 2019
7078bddb
(chore) update spec test
Jul 30, 2019
fa6b069b
(feat) reduce entities size
Jul 30, 2019
55bef31d
Merge branch 'feat/disable-comments-conversations' into 'release/3.8.0'
Jul 31, 2019
3633924c
(chore) v3.9.0
Jul 31, 2019
a8518f86
(chore) remove sms listener
Jul 31, 2019
72f56167
(feat) autodetect app version and build
Jul 31, 2019
93248111
(chore) clean up es-feed conditionals
Aug 01, 2019
847e3a30
(chore) remove console log
Aug 01, 2019
925a03b6
(fix) top bar navigation e2e
Aug 01, 2019
02394bbf
(fix) post flow e2e tests
Aug 01, 2019
9585bda3
(chore) add more delay discovery edit e2e
Aug 01, 2019
eb9b267b
(fix) nsfw selector on capture
Aug 02, 2019
2a71b2b1
(fix) activity editor error
Aug 02, 2019
19a89c9f
(feat) autodetect play store version
Aug 02, 2019
66a25402
Merge branch...
Aug 03, 2019
c35c7431
(fix) boost console error when entity is missing
Aug 05, 2019
2647d774
(fix) failing to upload image browserstack
Aug 05, 2019
351e917a
(fix) upload videos s3 stall
Aug 05, 2019
cd8dce66
Merge branch 'feat/fix-video-upload-issue.direct-s3' into 'release/3.8.0'
Aug 06, 2019
66c41ffe
Merge branch 'feat/fix-boost-console-render-error-missing-entity' into 'release/3.8.0'
Aug 06, 2019
10d7712e
Merge branch 'feat/fix-e2e-tests' into 'release/3.8.0'
Aug 06, 2019
fb7e4164
(feat) version bump for 3.8.0
Aug 06, 2019
0ced7435
(chore) update test snapshots
Aug 06, 2019
78c2b7d4
Merge branch 'feat/version-bump-for-release-3.8.0' into 'release/3.8.0'
Aug 06, 2019
1f0053eb
(feat) boosted content service offline
Aug 06, 2019
afcf26d5
Merge branch 'release/3.8.0' into release/3.9.0
Aug 07, 2019
821bdfc3
Merge branch 'release/3.9.0' into feat/cleanup-es-feeds-conditionals
Aug 07, 2019
71fca55f
Merge branch 'release/3.9.0' into feat/autodetect-app-version
Aug 07, 2019
2cf0c334
(feat) scroll latest media in capture
Aug 08, 2019
eb546bf9
(chore) remove snapshot
Aug 09, 2019
b29b800d
(fix) copy/paste issue on android
Aug 09, 2019
8bdcbde9
(feat) infinite scroll feed service
Aug 09, 2019
760fa50d
(bug) infinite feed error discovery and local storage of pagination token
Aug 09, 2019
cf44e7e7
Merge branch 'feat/fix-android-copy-paste-issue' into 'release/3.8.1'
Aug 12, 2019
d96b0497
(fix) copy paste android login screen
Aug 12, 2019
cb8d9f8f
Merge branch 'feat/fix-copypaste-login-android' into 'release/3.8.1'
Aug 12, 2019
ed0e54c5
Merge branch 'feat/infinite-scroll-feed-service' into 'release/3.8.1'
Aug 12, 2019
b24329f3
(chore) version bump 3.8.1
Aug 12, 2019
bcb0a60f
Merge branch 'feat/bump-version-3_8_1' into 'release/3.8.1'
Aug 12, 2019
60946947
(fix) end reached detection in feed service
Aug 12, 2019
22716933
Merge branch 'feat/fix-end-reached-detection-infinite-feed' into 'release/3.8.1'
Aug 13, 2019
e7087c0b
(fix) load next page when end reached
Aug 13, 2019
cb1a94a6
Merge branch 'feat/fix-end-reached-detection-condition' into 'release/3.8.1'
Aug 13, 2019
f08cc6a1
(chore) fix typo
Aug 13, 2019
e2f0b1de
Merge branch 'feat/fix-continue-typo' into 'release/3.8.1'
Aug 13, 2019
60aaa0cf
(fix) discovery feed opens in wrong image
Aug 14, 2019
b9711906
(feat) Use data from API call for contribution values on wallet page and add...
Aug 14, 2019
87e37cdb
(feat) Add Rewards notifications -
#1175
Aug 14, 2019
18ee19eb
(fix) should disable pagination in discovery feed screen
Aug 14, 2019
829d6b1d
Merge branch 'feat/fix-discovery-feed-view-correct-index' into 'release/3.8.1'
Aug 14, 2019
c34486a4
(fix) visited channels issues
Aug 14, 2019
70e50033
Merge branch 'feat/fix-last-visited-channel-issues' into 'release/3.8.1'
Aug 14, 2019
41ce194c
(feat) remember hastag on/off value
Aug 15, 2019
1b7dda50
(feat) update default settings script
Aug 15, 2019
70354547
Merge branch 'release/3.8.1' into release/3.9.0
Aug 15, 2019
15c96e38
Merge branch 'release/3.9.0' into feat/capture-image-scroll
Aug 15, 2019
6e99e690
Merge branch 'release/3.9.0' into feat/autodetect-app-version
Aug 15, 2019
a98f3915
(chore) update test snapshots
Aug 15, 2019
cb374cdf
(fix) boost injector enabled all tabs of discovery
Aug 16, 2019
Expand all
Hide whitespace changes
Inline
Side-by-side
.circleci/config.yml
View file @
a9798ba7
...
...
@@ -55,6 +55,9 @@ jobs:
steps
:
-
checkout
-
run
:
name
:
Install sentry cli for fastlane plugin
command
:
brew install getsentry/tools/sentry-cli
-
run
:
name
:
set Ruby version
command
:
echo "ruby-2.4" > ~/.ruby-version
...
...
@@ -129,6 +132,15 @@ jobs:
only
:
-
/release-*/
-
run
:
name
:
Prepare sentry release
command
:
fastlane preparesentry
working_directory
:
ios
-
persist_to_workspace
:
root
:
~/mobile-native/ios
paths
:
-
version
-
run
:
name
:
Upload to Testflight release
command
:
fastlane testflight
...
...
@@ -138,7 +150,27 @@ jobs:
-
/stable-*/
-
/release-*/
-
test/circle-ci
sentry
:
docker
:
-
image
:
getsentry/sentry-cli
working_directory
:
~/mobile-native
steps
:
-
attach_workspace
:
at
:
/tmp/workspace
-
run
:
name
:
Install git
command
:
|
apk add git
-
checkout
-
run
:
name
:
Tag sentry release
command
:
|
version=`cat /tmp/workspace/version`
echo Tagging release with ${version}
ls -a
# release created by fastlane preparesentry
sentry-cli releases set-commits --commit "Minds / Minds Mobile@${CIRCLE_SHA1}" ${version} --log-level=debug
sentry-cli releases finalize ${version}
workflows
:
version
:
2
node-ios
:
...
...
@@ -147,3 +179,6 @@ workflows:
-
ios
:
requires
:
-
node
-
sentry
:
requires
:
-
ios
.eslintrc.js
View file @
a9798ba7
module
.
exports
=
{
"
parser
"
:
"
babel-eslint
"
,
"
plugins
"
:
[
"
react
"
,
"
react-native
"
,
"
flowtype
"
],
"
extends
"
:
[
"
plugin:react-native/all
"
],
"
extends
"
:
[
"
plugin:react-native/all
"
,
"
plugin:react/recommended
"
],
"
env
"
:
{
"
react-native/react-native
"
:
true
},
"
rules
"
:
{
"
no-unused-vars
"
:
[
1
],
"
react/jsx-uses-vars
"
:
[
2
],
"
flowtype/boolean-style
"
:
[
2
,
"
boolean
"
...
...
.flowconfig
View file @
a9798ba7
...
...
@@ -31,6 +31,7 @@ emoji=true
esproposal.optional_chaining=enable
esproposal.nullish_coalescing=enable
esproposal.decorators=ignore
module.system=haste
module.system.haste.use_name_reducers=true
...
...
.githooks/pre-commit
0 → 100755
View file @
a9798ba7
#!/bin/sh
if
git commit
-v
--dry-run
|
grep
'!testcode'
>
/dev/null 2>&1
then
echo
"Trying to commit test code."
exit
1
else
exit
0
fi
\ No newline at end of file
.gitignore
View file @
a9798ba7
...
...
@@ -63,4 +63,6 @@ buck-out/
coverage/
# Sentry secrets
sentry.properties
\ No newline at end of file
sentry.properties
!/.githooks
\ No newline at end of file
App.js
View file @
a9798ba7
...
...
@@ -62,11 +62,7 @@ import feedsStorage from './src/common/services/sql/feeds.storage';
import
connectivityService
from
'
./src/common/services/connectivity.service
'
;
import
sqliteStorageProviderService
from
'
./src/common/services/sqlite-storage-provider.service
'
;
import
commentStorageService
from
'
./src/comments/CommentStorageService
'
;
import
{
Sentry
}
from
'
react-native-sentry
'
;
Sentry
.
config
(
'
https://d650fc58f2da4dc8ae9d95847bce152d@sentry.io/1538735
'
).
install
();
import
*
as
Sentry
from
'
@sentry/react-native
'
;
let
deepLinkUrl
=
''
;
...
...
@@ -83,8 +79,8 @@ sessionService.onLogin(async () => {
const
user
=
sessionService
.
getUser
();
Sentry
.
setUserContext
(
{
userID
:
user
.
guid
Sentry
.
configureScope
(
scope
=>
{
scope
.
setUser
({
id
:
user
.
guid
});
});
logService
.
info
(
'
[App] Getting minds settings and onboarding progress
'
);
...
...
AppErrors.js
View file @
a9798ba7
...
...
@@ -9,13 +9,54 @@ import {
import
{
onError
}
from
"
mobx-react
"
;
import
logService
from
'
./src/common/services/log.service
'
;
import
Sentry
from
'
react-native-sentry
'
;
import
*
as
Sentry
from
'
@sentry/react-native
'
;
import
{
isAbort
,
isNetworkFail
}
from
'
./src/common/helpers/abortableFetch
'
;
import
{
isApiError
}
from
'
./src/common/services/api.service
'
;
// Init Sentry (if not running test)
if
(
process
.
env
.
JEST_WORKER_ID
===
undefined
)
{
Sentry
.
init
({
dsn
:
'
https://d650fc58f2da4dc8ae9d95847bce152d@sentry.io/1538735
'
,
ignoreErrors
:
[
'
Non-Error exception captured with keys: code, domain, localizedDescription
'
,
// ignore initial error of sdk
],
beforeSend
(
event
,
hint
)
{
if
(
hint
.
originalException
)
{
// ignore network request failed
if
(
isNetworkFail
(
hint
.
originalException
))
{
return
null
;
}
// ignore aborts
if
(
isAbort
(
hint
.
originalException
))
{
return
null
;
}
// only log api 500 errors
if
(
isApiError
(
hint
.
originalException
)
&&
hint
.
originalException
.
status
<
500
)
{
return
null
;
}
}
// for dev only log into the console
if
(
__DEV__
)
{
console
.
log
(
'
sentry
'
,
event
,
hint
);
return
null
;
}
return
event
;
}
});
}
// Log Mobx global errors
onError
(
error
=>
{
console
.
log
(
error
);
logService
.
exception
(
error
);
})
// react-native-exception-handler global handlers
if
(
!
__DEV__
)
{
/**
* Globar error handlers
...
...
AppStores.js
View file @
a9798ba7
...
...
@@ -19,8 +19,6 @@ import keychain from './src/keychain/KeychainStore';
import
blockchainTransaction
from
'
./src/blockchain/transaction-modal/BlockchainTransactionStore
'
;
import
blockchainWallet
from
'
./src/blockchain/wallet/BlockchainWalletStore
'
;
import
blockchainWalletSelector
from
'
./src/blockchain/wallet/BlockchainWalletSelectorStore
'
;
import
payments
from
'
./src/payments/PaymentsStore
'
;
import
checkoutModal
from
'
./src/payments/checkout/CheckoutModalStore
'
;
import
capture
from
'
./src/capture/CaptureStore
'
;
import
withdraw
from
'
./src/wallet/tokens/WithdrawStore
'
;
import
hashtag
from
'
./src/common/stores/HashtagStore
'
;
...
...
@@ -55,8 +53,6 @@ const stores = {
blockchainWallet
:
new
blockchainWallet
(),
blockchainWalletSelector
:
new
blockchainWalletSelector
(),
channelSubscribersStore
:
new
channelSubscribersStore
(),
payments
:
new
payments
(),
checkoutModal
:
new
checkoutModal
(),
capture
:
new
capture
(),
withdraw
:
new
withdraw
(),
hashtag
:
new
hashtag
(),
...
...
__mocks__/fake/ActivitiesFaker.js
View file @
a9798ba7
...
...
@@ -14,6 +14,7 @@ function load(count) {
edited
:
""
,
guid
:
code
,
mature
:
false
,
time_created
:
"
1522036284
"
,
ownerObj
:{
guid
:
"
824853017709780997
"
,
type
:
"
user
"
,
...
...
@@ -36,6 +37,14 @@ function load(count) {
wire_totals
:
{
tokens
:
1000000000000000000
},
_list
:
{
viewed
:
{
viewed
:
new
Map
([[
"
1019155171608096768
"
,
true
]]),
addViewed
:
()
=>
{
return
;
}
}
},
getThumbSource
:
()
=>
{
return
{
source
:
'
http://thisisaurl
'
...
...
__tests__/activity/components/ActivityScreen.js
View file @
a9798ba7
...
...
@@ -18,6 +18,7 @@ jest.mock('../../../src/newsfeed/NewsfeedService');
import
{
getSingle
}
from
'
../../../src/newsfeed/NewsfeedService
'
;
import
entitiesService
from
'
../../../src/common/services/entities.service
'
;
jest
.
mock
(
'
../../../src/common/BaseModel
'
);
jest
.
mock
(
'
../../../src/newsfeed/activity/Activity
'
,
()
=>
'
Activity
'
);
jest
.
mock
(
'
../../../src/comments/CommentList
'
,
()
=>
'
CommentList
'
);
jest
.
mock
(
'
../../../src/common/components/CenteredLoading
'
,
()
=>
'
CenteredLoading
'
);
...
...
__tests__/activity/components/__snapshots__/Activity.js.snap
View file @
a9798ba7
...
...
@@ -17,7 +17,14 @@ exports[`Activity component renders correctly 1`] = `
<Pinned
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -63,6 +70,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -74,7 +82,14 @@ exports[`Activity component renders correctly 1`] = `
<OwnerBlock
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -120,6 +135,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -147,7 +163,14 @@ exports[`Activity component renders correctly 1`] = `
<ActivityActionSheet
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -193,6 +216,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -234,7 +258,7 @@ exports[`Activity component renders correctly 1`] = `
]
}
>
Invalid date
Mar 25, 2018, 20:51
</Text>
</TouchableOpacity>
</OwnerBlock>
...
...
@@ -248,7 +272,14 @@ exports[`Activity component renders correctly 1`] = `
<ExplicitText
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -294,6 +325,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -316,7 +348,14 @@ exports[`Activity component renders correctly 1`] = `
<Translate
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -362,6 +401,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -380,7 +420,14 @@ exports[`Activity component renders correctly 1`] = `
<MediaView
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -426,6 +473,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -450,7 +498,14 @@ exports[`Activity component renders correctly 1`] = `
<Actions
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -496,6 +551,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -513,7 +569,14 @@ exports[`Activity component renders correctly 1`] = `
<ActivityMetrics
entity={
ActivityModel {
"__list": null,
"__list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"allow_comments": true,
"attachment_guid": false,
"blurb": false,
...
...
@@ -559,6 +622,7 @@ exports[`Activity component renders correctly 1`] = `
"thumbs:down:user_guids": undefined,
"thumbs:up:count": undefined,
"thumbs:up:user_guids": undefined,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
__tests__/activity/components/__snapshots__/ActivityEditor.js.snap
View file @
a9798ba7
...
...
@@ -70,6 +70,8 @@ exports[`Activity editor component renders correctly 1`] = `
nsfwValue={Array []}
onLocking={[Function]}
onNsfw={[Function]}
onScheduled={[Function]}
timeCreatedValue={2018-03-26T03:51:24.000Z}
/>
</View>
<View
...
...
__tests__/activity/components/__snapshots__/ActivityScreen.js.snap
View file @
a9798ba7
...
...
@@ -18,6 +18,14 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
<CommentList
entity={
Object {
"_list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Object {
"1019155171608096768": true,
},
},
},
"attachment_guid": false,
"blurb": false,
"container_guid": "activityguid0",
...
...
@@ -42,6 +50,7 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"rowKey": "something0",
"shouldBeBlured": [MockFunction],
"thumbnail_src": false,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -54,6 +63,14 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
autoHeight={false}
entity={
Object {
"_list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Object {
"1019155171608096768": true,
},
},
},
"attachment_guid": false,
"blurb": false,
"container_guid": "activityguid0",
...
...
@@ -78,6 +95,7 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"rowKey": "something0",
"shouldBeBlured": [MockFunction],
"thumbnail_src": false,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -91,6 +109,14 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"state": Object {
"params": Object {
"entity": Object {
"_list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"attachment_guid": false,
"blurb": false,
"container_guid": "activityguid0",
...
...
@@ -115,6 +141,7 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"rowKey": "something0",
"shouldBeBlured": [MockFunction],
"thumbnail_src": false,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
@@ -134,6 +161,14 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"state": Object {
"params": Object {
"entity": Object {
"_list": Object {
"viewed": Object {
"addViewed": [Function],
"viewed": Map {
"1019155171608096768" => true,
},
},
},
"attachment_guid": false,
"blurb": false,
"container_guid": "activityguid0",
...
...
@@ -158,6 +193,7 @@ exports[`Activity screen component renders correctly with an entity as param 2`]
"rowKey": "something0",
"shouldBeBlured": [MockFunction],
"thumbnail_src": false,
"time_created": "1522036284",
"title": "TITLE",
"type": "activity",
"wire_totals": Object {
...
...
__tests__/auth/__snapshots__/ForgotPassword.js.snap
View file @
a9798ba7
...
...
@@ -13,7 +13,7 @@ exports[`ForgotPassword component should renders correctly 1`] = `
style={
Array [
Object {
"color": "
white
",
"color": "
#FFFFFF
",
},
Object {
"fontSize": 14,
...
...
__tests__/auth/__snapshots__/ForgotScreen.js.snap
View file @
a9798ba7
...
...
@@ -77,7 +77,7 @@ exports[`ForgotScreen component should renders correctly 1`] = `
style={
Array [
Object {
"color": "
white
",
"color": "
#FFFFFF
",
},
Object {
"fontSize": 14,
...
...
__tests__/auth/__snapshots__/LoginForm.js.snap
View file @
a9798ba7
...
...
@@ -342,7 +342,7 @@ exports[`LoginForm component should renders correctly 1`] = `
style={
Array [
Object {
"color": "
white
",
"color": "
#FFFFFF
",
},
Object {
"fontWeight": "bold",
...
...
@@ -396,7 +396,7 @@ exports[`LoginForm component should renders correctly 1`] = `
style={
Array [
Object {
"color": "
white
",
"color": "
#FFFFFF
",
},
]
}
...
...
@@ -506,7 +506,7 @@ exports[`LoginForm component should renders correctly 1`] = `
"padding": 10,
},
Object {
"color": "
white
",
"color": "
#FFFFFF
",
},
]
}
...
...
@@ -634,7 +634,7 @@ exports[`LoginForm component should renders correctly 1`] = `
"alignItems": "center",
"backgroundColor": "white",
"borderColor": "#777777",
"borderRadius":
15
,
"borderRadius":
20
,
"borderWidth": 1,
"margin": 4,
"opacity": 1,
...
...
@@ -671,7 +671,7 @@ exports[`LoginForm component should renders correctly 1`] = `
"alignItems": "center",
"backgroundColor": "white",
"borderColor": "#4690D6",
"borderRadius":
15
,
"borderRadius":
20
,
"borderWidth": 1,
"margin": 4,
"opacity": 1,
...
...
__tests__/capture/CapturePoster.js
View file @
a9798ba7
...
...
@@ -331,7 +331,8 @@ describe('cature poster component', () => {
// should be called only once
expect
(
capture
.
post
.
mock
.
calls
.
length
).
toBe
(
1
);
expect
(
capture
.
post
.
mock
.
calls
[
0
][
0
]).
toEqual
({
nsfw
:
[],
message
:
"
some awesome post
"
,
wire_threshold
:
null
});
const
entity
=
capture
.
post
.
mock
.
calls
[
0
][
0
];
expect
(
capture
.
post
.
mock
.
calls
[
0
][
0
]).
toEqual
({
nsfw
:
[],
message
:
"
some awesome post
"
,
wire_threshold
:
null
,
"
time_created
"
:
entity
.
time_created
});
expect
(
result
).
toEqual
(
response
)
...
...
@@ -400,12 +401,14 @@ describe('cature poster component', () => {
// should be called only once
expect
(
capture
.
post
.
mock
.
calls
.
length
).
toBe
(
1
);
const
entity
=
capture
.
post
.
mock
.
calls
[
0
][
0
];
expect
(
capture
.
post
.
mock
.
calls
[
0
][
0
]).
toEqual
({
nsfw
:
[],
message
:
"
some awesome post
"
,
wire_threshold
:
null
,
facebook
:
1
,
twitter
:
1
twitter
:
1
,
time_created
:
entity
.
time_created
});
done
();
...
...
@@ -446,14 +449,15 @@ describe('cature poster component', () => {
// should be called only once
expect
(
capture
.
post
).
toBeCalled
();
const
entity
=
capture
.
post
.
mock
.
calls
[
0
][
0
];
// should send the attachment data
console
.
log
(
capture
.
post
.
mock
.
calls
);
expect
(
capture
.
post
.
mock
.
calls
[
0
][
0
]).
toEqual
({
nsfw
:
[],
message
:
"
some awesome post
"
,
wire_threshold
:
null
,
attachment_guid
:
1000
,
attachment_license
:
''
}
attachment_license
:
''
,
time_created
:
entity
.
time_created
}
);
// should return server response
expect
(
result
).
toEqual
(
response
)
...
...
__tests__/capture/CapturePosterFlags.js
View file @
a9798ba7
...
...
@@ -16,6 +16,16 @@ jest.mock('../../src/capture/CaptureStore');
jest
.
mock
(
'
../../src/common/components/LicensePicker
'
,
()
=>
'
LicensePicker
'
);
jest
.
mock
(
'
../../src/newsfeed/topbar/TagsSubBar
'
,
()
=>
'
TagsSubBar
'
);
Date
=
class
extends
Date
{
constructor
(
date
)
{
if
(
date
)
{
return
super
(
date
);
}
return
new
Date
(
'
2018-09-20T23:00:00Z
'
);
}
}
defaultState
=
{
mature
:
false
,
...
...
@@ -53,6 +63,7 @@ const testRenderWithValue = (value) => {
onMature
=
{
fn
}
onShare
=
{
fn
}
onLocking
=
{
fn
}
onScheduled
=
{
fn
}
/
>
).
toJSON
();
expect
(
preview
).
toMatchSnapshot
();
...
...
@@ -104,7 +115,7 @@ describe('cature poster flags component', () => {
const
hashtagStore
=
new
HashtagStore
();
store
.
loadSuggestedTags
.
mockResolvedValue
();
cons
t
capturePosterFlag
=
renderer
.
create
(
le
t
capturePosterFlag
=
renderer
.
create
(
<
CapturePosterFlags
capture
=
{
store
}
hashtag
=
{
hashtagStore
}
...
...
@@ -125,6 +136,19 @@ describe('cature poster flags component', () => {
store
.
attachment
.
hasAttachment
=
true
;
capturePosterFlag
=
renderer
.
create
(
<
CapturePosterFlags
capture
=
{
store
}
hashtag
=
{
hashtagStore
}
matureValue
=
{
defaultState
.
mature
}
shareValue
=
{
defaultState
.
share
}
lockValue
=
{
defaultState
.
lock
}
onMature
=
{
fn
}
onShare
=
{
fn
}
onLocking
=
{
fn
}
/
>
);
picker
=
capturePosterFlag
.
root
.
findAllByType
(
'
LicensePicker
'
);
// check there is 1 license picker
...
...
__tests__/capture/__snapshots__/CapturePosterFlags.js.snap
View file @
a9798ba7
This diff is collapsed.
Click to expand it.
__tests__/channel/__snapshots__/ChannelActions.js.snap
View file @
a9798ba7
...
...
@@ -3,18 +3,19 @@
exports[`channel actions component should renders correctly 1`] = `
<View
style={
Object {
"alignItems": "center",
"backgroundColor": "#FFF
",
"flexDirection": "row
",
"height": 40
,
"justifyContent": "flex-end",
"paddingLeft
":
8
,
"width": 40
,
}
Array [
Object {
"flexDirection": "row
",
"justifyContent": "flex-end
",
}
,
Object {
"marginTop
":
10
,
}
,
]
}
>
<View
accessibilityLabel="Wire Button"
accessible={true}
isTVSelectable={true}
onResponderGrant={[Function]}
...
...
@@ -25,12 +26,16 @@ exports[`channel actions component should renders correctly 1`] = `
onStartShouldSetResponder={[Function]}
style={
Object {
"alignContent": "center",
"alignItems": "center",
"alignSelf": "center",
"flex": 1,
"backgroundColor": "white",
"borderColor": "#4690D6",
"borderRadius": 20,
"borderWidth": 1,
"flexDirection": "row",
"justifyContent": "center",
"margin": 4,
"opacity": 1,
"padding": 4,
}
}
>
...
...
@@ -39,10 +44,17 @@ exports[`channel actions component should renders correctly 1`] = `
style={
Array [
Object {
"color":
"rgb(70, 144, 214)"
,
"fontSize":
40
,
"color":
undefined
,
"fontSize":
18
,
},
undefined,
Array [
Object {
"marginLeft": 5,
},
Object {
"color": "#4690D6",
},
],
Object {
"fontFamily": "Ionicons",
"fontStyle": "normal",
...
...
@@ -54,30 +66,74 @@ exports[`channel actions component should renders correctly 1`] = `
>
</Text>
<Text
style={
Array [
Object {
"color": "#4690D6",
},
Array [
Object {
"marginLeft": 5,
},
Object {
"marginRight": 5,
},
],
]
}
>
Wire
</Text>
</View>
<Text
allowFontScaling={false}
onPress={[Function]}
<View
accessibilityLabel="More"
accessible={true}
isTVSelectable={true}
onResponderGrant={[Function]}
onResponderMove={[Function]}
onResponderRelease={[Function]}
onResponderTerminate={[Function]}
onResponderTerminationRequest={[Function]}
onStartShouldSetResponder={[Function]}
style={
Array [
Object {
"color": undefined,
"fontSize": 24,
},
Object {
"color": "#888888",
"paddingLeft": 10,
},
Object {
"fontFamily": "Ionicons",
"fontStyle": "normal",
"fontWeight": "normal",
},
Object {},
]
Object {
"alignItems": "center",
"backgroundColor": "white",
"borderColor": "#4690D6",
"borderRadius": 20,
"borderWidth": 1,
"flexDirection": "row",
"justifyContent": "center",
"margin": 4,
"opacity": 1,
"padding": 4,
}
}
>
</Text>
<Text
style={
Array [
Object {
"color": "#4690D6",
},
Array [
Object {
"marginLeft": 5,
},
Object {
"marginRight": 5,
},
],
]
}
>
More
</Text>
</View>
</View>
`;
Prev
1
2
3
4
5
…
7
Next