1

first I sorry about path question...

HI

I know that lastest firefox doesn't open in selenium so

I fount marionette but button doesn't working in morionette

so I decide to use old version firefox using FirefoxBinary

I want solve this problem reference to this link

In test.py

from selenium import webdriver
from selenium.webdriver.firefox.firefox_binary import FirefoxBinary

class NewVisitorTest(StaticLiveServerTestCase):
    def setUp(self):
        binary = FirefoxBinary('../../firefox/firefox')
        driver = webdriver.Firefox(firefox_binary=binary)

but...

FileNotFoundError: [Errno 2] No such file or directory: '../../firefox/firefox'

so i change the code

binary = FirefoxBinary('~/Document/firefox/firefox')

but it export same error....

test.py -pwd is

/Users/hanminsoo/Documents/TDD_test/TDD_Test/superlists/functional_tests/test.py

firfox -pwd is

/Users/hanminsoo/Documents/firefox/firefox

what is the problem in my code???

Community
  • 1
  • 1
Jade Han
  • 1,185
  • 5
  • 15
  • 36

1 Answers1

1

Try using absolute paths instead, and ensure your path spelling:

binary = FirefoxBinary('~/Documents/firefox/firefox')
Adam
  • 335
  • 1
  • 2
  • 7
  • thank you about your answer but I trying this solution(I have double check about my path spell , i have mistake about this question page sorry..) but it doesn't working too So I solved my problem using downgrade firfox,, any way thank you Adam! – Jade Han Jul 20 '16 at 06:14