Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

test: use os.tmpdir() #1126

Merged
merged 3 commits into from
Dec 5, 2017
Merged

test: use os.tmpdir() #1126

merged 3 commits into from
Dec 5, 2017

Conversation

richardschneider
Copy link
Contributor

See #1075

@ghost ghost assigned richardschneider Dec 4, 2017
@ghost ghost added the status/in-progress In progress label Dec 4, 2017
@codecov
Copy link

codecov bot commented Dec 5, 2017

Codecov Report

Merging #1126 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1126   +/-   ##
=======================================
  Coverage   83.49%   83.49%           
=======================================
  Files         122      122           
  Lines        2732     2732           
=======================================
  Hits         2281     2281           
  Misses        451      451

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 54ea2c7...0a7c9af. Read the comment docs.

@ghost ghost assigned daviddias Dec 5, 2017
@@ -65,7 +65,7 @@ describe('daemon', () => {
let ipfs

beforeEach(() => {
repoPath = '/tmp/ipfs-test-not-found-' + Math.random().toString().substring(2, 8)
repoPath = path.join(os.tmpdir(), 'ipfs-test-not-found-' + Math.random().toString().substring(2, 8))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't mind here as well (ref ipfs-inactive/ipfs-performance-profiling#12 (comment))

@@ -19,7 +21,7 @@ describe('create node', function () {
this.timeout(80 * 1000)

const node = new IPFS({
repo: '/tmp/ipfs-repo-' + Math.random(),
repo: path.join(os.tmpdir(), 'ipfs-repo-' + Math.random()),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@diasdavid Good idea. I don't like seeing Math.random, because I always worry if a cryptographically secure P/RNG should be used.

@daviddias
Copy link
Member

image

Seems like CI uses windows-386 and currently there is no go-ipfs build available due to: ipfs/distributions#165

@richardschneider
Copy link
Contributor Author

@diasdavid Yes, 386 builds are failing, I added #1127

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants