Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - efko

Pages: 1 ... 18 19 [20] 21 22 ... 52
286
I believe next period will bring more positive opinions since some people are working to improve all the things that they can. And without doubts, incoming year will be even better (maybe Lilith II is incoming or something similar, who knows)  8)

287
New Members Introduction / Re: New guy here!
« on: 16 December 2019, 21:39:52 »
Welcome to the forum :)

288
Humor / Re: Funny Videos
« on: 16 December 2019, 21:36:06 »
The first moment where Tom underestimated Jerry.
Limited edition.
After that you know entire story :))

https://youtu.be/iWAP6vs6soE?t=312

289
New Projects / Re: Titan Quest - Titanomachy Mod ( Development )
« on: 11 December 2019, 18:54:50 »
You definitely need to make more lions, they are awesome, so experiment different things on them, colors...

290
General Discussion / Re: Boosting the forum population
« on: 30 November 2019, 05:33:39 »
The biggest problem can be the english language, some  people can have troubles on pronunciation/words. I think you dont need to worry much about this , im sure no one will make fun of it.

Look at my exemple , my english isnt 100% perfect , sometimes  it sux, but its okay, you will never know if you dont try :)
Someone should explain to me why I always laugh when sauruz is talking about some foruNs. I was thinking for a long time that something is wrong with me when sauruz use that word, but meh, its just funny, always  ;D

Torstein, link this topic on discord as well and call people there. I hope that there will be interested people to join you.
Also good idea can be to @mention some people here on forum or to send pm. Also we have clock for meeting purpose

 《 this is not just a text
Code: [Select]
[countdown=MONTH,DAY,YEAR,HOUR,MINUTE][/countdown]

291
General Discussion / Re: Interesting Myth Stories
« on: 29 November 2019, 01:04:00 »
This site has nice stories about Egyptian mythology http://www.egyptianmyths.net/

292
Java / Re: Osnove jave
« on: 24 November 2019, 14:42:19 »
Spoiler for Hiden:
Hardver

Zbog specifičnog setapa u kom trenutno radim, koristim dva laptopa. Nekada je nezahvalno imati dve mašine, ali s obzirom na to da je većina stvari koje su mi potrebne za rad (a i privatno) na cloud–u, ovo i nije neka prepreka. Dakle, jedan fini sync na svim uređajima rešava stvar 😊.

Sa jedne strane, tu je moćni Lenovo Z51-70, sa grafikom spremnom za opasnu multimediju i još bolje igre. Kada sam dobio ovu mašinu, tadašnji Pro Evolution Soccer je gurao na max (hehe… nadam se da šefica ne čita ovo 😊). Full HD displej od 15’’ je prijatan za svakodnevni rad i kodiranje. Kombinacija i7 procesora, 16GB rama i SSD-a mi pruža pouzdanost i brzinu, pa čak i onda kad imam gomilu otvorenih tabova u Chromu, a pored toga još par IDE — ne desi se da štuca ili zakuca.

Sa druge strane je Lenovo ThinkPad sa displejom od 13’’, znatno slabiji od prethodno pomenutog, ali zato vrlo praktičan. Ova mašina je za mašina za pokret 😊. Prvo zato što je lagana, a drugo, zato što je jednim kablom zakačena na dock station i kada treba odjuriti negde sa njom, lako je iskopčati, spakovati i poneti. Sjajna je za administrativne i office zadatke, tj. za menadžerske taskove.

Dok sam u kancelariji za stolom, oba laptopa su zakačena za po jedan monitor. Radi se o modelima DELL U2412M. Nemam posebnih komentara za monitore, veliki su ekrani i prijatni za moje osetljive oči 😀. Uz to, dva puta po Logitech M235 bežični miš. Nisam zahtevan po pitanju periferija, dodatne tastature ne koristim, a od miševa tražim da nemaju repove iliti kablove.

Slušalice, tj. headset na poslu uglavnom koristim za onlajn sastanke, a i kada želim da se fokusiram na rad ili na slušanje muzike. Posle godina korišćenja raznih slušalica koje se kablom na USB priključuju na komp i moje frustracije zbog zapetljanih kablova i njihovog raspetljavanja minut pred sastanak, odlučio sam da uzmem Logitech H800. Vrlo sam zadovoljan koliko su slušalice udobne, kao i samim kvalitetom zvuka. Jedno što bih voleo da baterija traje malo duže…

Pored ovih slušalica koje koristim isključivo za posao, za sve ostale privatne potrebe imam Huawei Honor AM61. Imaju taj silikonski dodatak koji fiksira slušalicu na uho, što je jako zgodno za mene jer mi iz jednog uha konstanto ispadna jedna klasična bubica 😀. Njih redovno koristim za trening, zvuk je odličan, prilično je izolovana spoljašnja buka i baterija traje dugo.

Pored dva laptopa, tu je i iPad. Njega koristim u svrhe testiranja i to je sve. Nisam previše sklon prema Apple uređajima, pa mi možda zato i nije toliko interesantan.

Uvek i svuda uz mene ide Huawei P20. Bio sam strastveni Samsung korisnik, ali sam pre godinu i po dana odlučio da malo promenim i probam Huawei. I nisam se pokajao. Ovaj telefon mi daje mogućnost da završim većinu zadataka vezanih za posao, sve sem kodiranja… to još uvek nisam probao 😊. Privatno ga koristim za društvene mreže, fotografije, podsetnike, kalendar, trening, kurseve… sve.

Tu su uvek sveska i olovka za brze beleške sa sastanaka i ideje koje mi u momentu padnu na pamet. Ovo se ispostavilo kao najsigurnije sredstvo u smislu bezbednosti informacija, jer… to što ja napišem niko ne može da pročita 😊.
Softver

Nekoliko godina unazad radim na projektima koji su usko vezani za Microsoft tehnologije, pa samim tim koristim i njihove alate.

Outlook je neizbežan kao osnovno sredstvo komuniciranja mejlom, za zakazivanje sastanaka, praćenje taskova i sinhronizaciju sa kolegama. Koristim ga od prvog dana na poslu i bilo bi mi čudno da mi dan počne bez njega.

Skype, Skype for Business i Slack su tu za dopisivanje, brzu komunikaciju, pozive, video pozive i onlajn sastanke. Slack mi je najdraži, zbog velike mogućnosti prilagođavanja, a Skype i Skype for Business verzije za smartphone (što se mene tiče) mogu da se koriste samo kad mora jer su spori, nepouzdani i nestabilini.

Za praćenje rada i organizaciju posla u timu koristimo JIRA-u, koju takođe koristim kao alat za prijavljivanje bagova. Iz istog paketa, dolazi i Confluence, gde držimo dokumentaciju i beleške na nivou tima. Ono što je dosta zgodno je to što ova dva alata imaju integraciju pa je lako uvezati dnevne taskove sa dokumentacijom i specifikacijama.

Git – pretpostavljam da je svako ko se bavi developmentom bar čuo za Git, iako ga možda i ne koristi. Radimo na velikim, jedinstvenim i kompleksnim sistemima i za kontrolu verzije koda koristimo ovaj sistem.

Bitbucket je još jedan alat iz Attlassian paketa, prvenstveno zadužen kao skladište sistema za kontrolu verzije koda. Pored toga, izuzetno olakšava code review koji radimo u okviru tima. Ima odličnu podršku za continious delivery, gde možete kreirati pipeline za svoje potrebe, bilo da je u pitanju build, test ili deploy koda.
Testing

Hm… Odakle početi… Testing alati u mnogome zavise od tehnologija na konkretnom projektu, tako da sam imao prilike da se upoznam sa mnogim. Hajde da počnem od test management alata.

TestLink za pisanje testova, njihovu organizaciju, kreiranje test planova, izvršavanje testova, kreiranje raznih izveštaja. Kroz projekte sam uglavnom ovaj alat koristio za test menadžment, a prednost mu je to što je besplatan i open source. Jedina zamerka može da bude na UI koji na prvi pogled nije toliko intuitivan, ali je posle nekog vremena korišćenja lako navići se na njega.
Test automatizacija

Za UI testiranje sam najčešće koristio Selenium, i u mom slučaju je to u kombinaciji sa C#, uz SpecFlow kao dodatak za Behivor Driven Development i NUnit kao .NET framework za testiranje.

Godinu dana unazad radim u timu koji razvija aplikaciju čiji je front-end pisan u React-u. Dolaskom ovog i sličnih JavaScript framework-a, došli su i novi test alati. Malo guglanja šta je najbolje koristiti za automatsko testiranje React aplikacija će vas dovesti do Cypress-a. Ovo je jako moćan alat, koji radi odlično sa JavaScript aplikacijama. Ima dosta korisnih funkcionalnosti i prilično je intuitivan, čak i za mene koji nisam bio toliki poznavalac JavaScript-a kada sam počeo da ga koristim.

Sem testiranja UI, integraciono testiranje i testiranje API i servisa obavljam uglavnom koristeći SoapUI i Postman. Zbog brže isporuke softvera, a samim tim i dobijanja rezultata testova, uglavnom i ovaj deo automatizujem pisanjem jedinstvenih framework-a, kombinacijom C# i NUnit-a.
Chrome

Chrome mi je podrazumevani browser. Koristan mi je sync pa mogu lako da podesim svoj nalog na više uređaja. Od ekstenzija koristim AdBlock – jasno mi je da mnogi zarađuju od reklama, a moje mišljenje je da se u poslednje vreme preteruje s tim, pa gledam da ih eliminišem na svakom koraku. Tek kad isključim AdBlock na nekom sajtu vidim u stvari kolika je razlika.

DuckDuckGo Privacy Essentials – ovo sam nedavno počeo da koristim na predlog kolege, što je u suštini anti tracker. Takođe, ovaj dodatak podesi automatski pretraživač na DuckDuckGo koji daje generalne rezultate pretrage, a ne kreirane na osnovu algoritma tracker-a, istorije… i čega god još pored toga.

LastPass Password Manager, za čuvanje svih kredencijala, jer mi je dosadilo da posle nekog vremena iznova koristim Forgot your password.  Takođe ima autologin na sajtove koji su sačuvani.

MagicActionsForYouTube mi je isprva bio interesantan samo zbog jednog, a to je bio prekidač u gornjem levom uglu (nalik onom za bojler za kupatilo) koji uključi-isključi dark theme. A posle sam video da ima i drugih kul opcija kao volume na mouse scroll, autoplay on only if list, cinema mode, no adds, no annotations.

MateTranslate – vrlo zgodan prevodilac koji na dupli klik otvara context menu sa prevodom.

The Great Suspender koji stavlja neaktivne tabove u sleep mode i tako štedi resurse mašine.
I za kraj…

Kao što sam već spomenuo, radim u vrlo dinamičnom okruženju, kao i većina IT profesionalaca, što iziskuje da pratim trendove, učim nove tehnologije i baratam novim alatima. Dao sam vam opis skupa alata koje trenutno koristim, što se vrlo brzo može promeniti, jer dok čitate ovaj tekst moguće da koristim neki novi

293
Humor / Re: Funny Videos
« on: 24 November 2019, 02:50:09 »

294
Java / Re: Java-Selenium/Chronium
« on: 22 November 2019, 17:06:44 »
Domaci

110
Spoiler for Hiden:
Quote

package dom21_18_11;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.WebElement;
import java.util.List;



public class Eclipse5element {

public static void main(String[] args) throws InterruptedException {
// Sa sledećeg link-a
// https://accounts.eclipse.org/user/register?destination=user/login%3Ftakemeback%3Dhttps%253A//www.eclipse.org/
// Izdvojiti 5 elementa koristeći različite selektore.
// Napomena: Zadatak postaviti u folderu 21_18-11-2019

System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();
    //    driver.manage().window().maximize();
    //    driver.get("http://google.com");
 

driver.get("https://accounts.eclipse.org/user/register?destination=user/login%3Ftakemeback%3Dhttps%253A//www.eclipse.org/");
Thread.sleep(3000);

driver.findElement(By.id("email")).click();



}

}





111
Spoiler for Hiden:
Quote

package dom22_19_11;

public class DropdownEbay {

public static void main(String[] args) {
// Sa sajta https://www.ebay.com/, izabrati dropdown listu po izboru, odstampati njene vrednosti i postaviti vrednost po izboru.



}

}





295
Java / Re: Java-Selenium/Chronium
« on: 22 November 2019, 17:02:33 »
110
Spoiler for Hiden:
Quote






111
Spoiler for Hiden:
Quote






110
Spoiler for Hiden:
Quote






111
Spoiler for Hiden:
Quote






110
Spoiler for Hiden:
Quote






111
Spoiler for Hiden:
Quote






110
Spoiler for Hiden:
Quote






111
Spoiler for Hiden:
Quote






296
Java / Re: Java-Selenium/Chronium/TestNG
« on: 22 November 2019, 16:55:49 »
119
Spoiler for Hiden:
Quote

package aTest1;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.support.ui.Select;
import org.testng.Assert;
import org.testng.annotations.AfterTest;
import org.testng.annotations.BeforeTest;
import org.testng.annotations.Test;

public class TestNGLinks {
// Posetiti url: https://accounts.eclipse.org/user/register
// sakupiti sve linkove iz footera (bez linkova sa drustvenih mreza)
// i proveriti da li postoji link sa tekstom "About Us"

public String baseUrl = "https://accounts.eclipse.org/user/register";
WebDriver driver;

@BeforeTest
public void setup() {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
driver = new ChromeDriver();
}

@Test
public void aboutUsExists() throws InterruptedException {
driver.get(baseUrl);
Thread.sleep(2000);

List<WebElement> links = driver.findElements(By.cssSelector("footer section a"));

boolean found = false;
for (int i = 0; i < links.size(); i++) {
if(links.get(i).getText().contains("About Us")) {
found = true;
}
}

Assert.assertTrue(found);
}

@AfterTest
public void quit() {
// driver.close();
}
}




120
Spoiler for Hiden:
Quote

package aTest1;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.support.ui.Select;
import org.testng.Assert;
import org.testng.annotations.AfterTest;
import org.testng.annotations.BeforeTest;
import org.testng.annotations.Test;

public class TestNGEclipseRegistration {
public String baseUrl = "https://accounts.eclipse.org/user/register";
WebDriver driver;

@BeforeTest
public void setup() {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
driver = new ChromeDriver();
}

@Test
public void verifyHomePageTitle() throws InterruptedException {
driver.get(baseUrl);
Thread.sleep(2000);

WebElement selectInput = driver.findElement(By.cssSelector("#user-register-form select"));
Select select = new Select(selectInput);
List<WebElement> options = select.getOptions();
Assert.assertEquals(options.size(), 251);
}

@AfterTest
public void quit() {
// driver.close();
}
}




121
Spoiler for Hiden:
Quote

package aTest1;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.interactions.Actions;
import org.testng.Assert;
import org.testng.annotations.AfterTest;
import org.testng.annotations.BeforeTest;
import org.testng.annotations.Test;

public class TestNGEbayPagination {
public String baseUrl = "https://www.ebay.com";
WebDriver driver;

@BeforeTest
public void setup() {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
driver = new ChromeDriver();
}

@Test
public void verifyHomePageTitle() throws InterruptedException {
driver.get(baseUrl);
Thread.sleep(2000);

// search term "shoes"
WebElement searchInput = driver.findElement(By.name("_nkw"));
searchInput.sendKeys("shoes");
searchInput.sendKeys(Keys.ENTER);

List<WebElement> itemsPerPage = driver.findElements(By.cssSelector("#ipp-menu-list li a"));
WebElement a = itemsPerPage.get(0);
driver.get(a.getAttribute("href"));

Thread.sleep(3000);

List<WebElement> result = driver.findElements(By.cssSelector("ul.srp-results li.s-item"));

Assert.assertEquals(result.size(), 24);
}

@AfterTest
public void quit() {
// driver.close();
}
}




297
Java / Java-Selenium/Chronium
« on: 22 November 2019, 16:55:14 »
110
Spoiler for Hiden:
Quote

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;

public class Test {

public static void main(String[] args) {

System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.google.com");
driver.findElement(By.className("gLFyf")).sendKeys("IT Bootcamp");
driver.findElement(By.className("gLFyf")).sendKeys(Keys.ENTER);
}

}




111
Spoiler for Hiden:
Quote

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class Test2 {

public static void main(String[] args) throws InterruptedException {

System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.youtube.com");
Thread.sleep(3000);
//*[@id="search"]
WebElement wb=driver.findElement(By.xpath("//*[@id=\"search\"]"));
wb.click();
wb.sendKeys("Java");

driver.findElement(By.xpath("//*[@id=\"search-icon-legacy\"]")).click();
}

}




112
Spoiler for Hiden:
Quote


Test3Calc.java
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class Test3Calc {

public static void main(String[] args) throws Exception {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.desmos.com/scientific");
Thread.sleep(3000);
WebElement wb9= driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[1]/div[7]/span"));
wb9.click();
wb9.click();

WebElement wb8=driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[1]/div[6]/span"));
wb8.click();

WebElement wbplus=driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[4]/div[8]/span"));
wbplus.click();

WebElement wb4=driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[2]/div[5]/span"));
wb4.click();
WebElement wb0=driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[4]/div[5]/span"));
wb0.click();
wb8.click();

WebElement wbE=driver.findElement(By.xpath("//*[@id=\"main\"]/div/div/div/div[3]/div[2]/div/div/div[4]/div[9]/span"));

wbE.click();

}

}




113
Spoiler for Hiden:
Quote


package travel;

import java.util.ArrayList;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class TravelLogin {

public static void main(String[] args) throws InterruptedException {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.phptravels.net/admin");
Thread.sleep(3000);
// By.cssSelector("[name='email']")
driver.findElement(By.name("email")).sendKeys("admin@phptravels.com");
driver.findElement(By.name("password")).sendKeys("demoadmin");
driver.findElement(By.className("checkbox")).click();

driver.findElement(By.tagName("button")).click();
}

}




114
Spoiler for Hiden:
Quote


package travel;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class EbayShoes {

public static void main(String[] args) throws InterruptedException {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.ebay.com/sch/i.html?_from=R40&_trksid=m570.l1313&_nkw=shoes&_sacat=0");
Thread.sleep(3000);

List<WebElement> cards =
driver.findElements(By.className("s-item__title"));

for (int i = 0; i < cards.size(); i++) {
WebElement card = cards.get(i);
System.out.println(card.getText());
}
}

}




115
Spoiler for Hiden:
Quote

package z11192019;


import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.support.ui.Select;


public class SelectDropdown {

public static void main(String[] args) throws InterruptedException {

//Otici na sajt https://www.ebay.com zatim na
//Advanced Search, na novoj stranici iz dropdown-a liste "In this category:"
//izvuci sve podatke i proveriti da li postoji kategorija Books
//Ukoliko postoji izabrati je ukoliko ne postoji izabrati kategoriju Art
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.ebay.com/");
Thread.sleep(3000);

WebElement wbAdv = driver.findElement(By.id("gh-as-td"));
wbAdv.click();
Thread.sleep(3000);

WebElement selectElement = driver.findElement(By.id("e1-1"));
Select select = new Select(selectElement);
List<WebElement> allOptions = select.getOptions();

boolean booksFound = false;
for (int i = 0; i < allOptions.size(); i++)
{
System.out.println(allOptions.get(i).getText());
if (allOptions.get(i).getText().contains("Books"))
{
booksFound = true;
}
}
// art books travel
if (booksFound)
{
select.selectByVisibleText("Books");
}
else
{
select.selectByVisibleText("Art");
}

}




116
Spoiler for Hiden:
Quote

package z11192019;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class EbayShoes {

public static void main(String[] args) throws InterruptedException {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.ebay.com/");
Thread.sleep(2000);

WebElement searchInput = driver.findElement(By.name("_nkw"));
searchInput.sendKeys("shoes");
searchInput.sendKeys(Keys.ENTER);

List<WebElement> result = driver.findElements(By.cssSelector("ul.srp-results li.s-item"));

for (int i = 0; i < result.size(); i++) {
WebElement card = result.get(i);
/// findElement unutar WebElementa umesto driver-a
WebElement title = card.findElement(By.className("s-item__title"));
WebElement price = card.findElement(By.className("s-item__price"));

System.out.println(title.getText() + ": " + price.getText());
}
}

}




117
Spoiler for Hiden:
Quote

package z11192019;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;

public class EbayFreeShippingShoes {

public static void main(String[] args) throws InterruptedException {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.ebay.com/");
Thread.sleep(2000);

WebElement searchInput = driver.findElement(By.name("_nkw"));
searchInput.sendKeys("shoes");
searchInput.sendKeys(Keys.ENTER);

List<WebElement> result =
driver.findElements(By.cssSelector("ul.srp-results li.s-item"));

for (int i = 0; i < result.size(); i++) {
WebElement card = result.get(i);
WebElement title = card.findElement(By.className("s-item__title"));
WebElement price = card.findElement(By.className("s-item__price"));
// card.findElement(By.cssSelector("span.s-item__shipping.s-item__logisticsCost"));
WebElement shipping = card.findElement(By.className("s-item__shipping"));

if (shipping.getText().contains("Free International Shipping")) {
System.out.println(title.getText() + ": " + price.getText() + " " + shipping.getText());

}
}


}

}




118
Spoiler for Hiden:
Quote

package z11192019;

import java.util.List;

import org.openqa.selenium.By;
import org.openqa.selenium.Keys;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.support.ui.Select;

public class EbayAddToCart {
public static void main(String[] args) throws InterruptedException {
System.setProperty("webdriver.chrome.driver", "driver-lib\\chromedriver.exe");
WebDriver driver = new ChromeDriver();

driver.get("https://www.ebay.com/");
Thread.sleep(2000);

WebElement searchInput = driver.findElement(By.name("_nkw"));
searchInput.sendKeys("shoes");
searchInput.sendKeys(Keys.ENTER);

List<WebElement> result = driver.findElements(By.cssSelector("ul.srp-results li.s-item"));

WebElement card = result.get(0);
card.click();
Thread.sleep(2000);


List<WebElement> selectElements =
driver.findElements(By.cssSelector("form[name='viactiondetails'] select"));

WebElement selectElement = selectElements.get(0);
Select select = new Select(selectElement);
select.selectByIndex(1);

WebElement selectElement2 = selectElements.get(1);
Select select2 = new Select(selectElement2);
select2.selectByIndex(1);

driver.findElement(By.id("isCartBtn_btn")).click();

}
}





298
General Discussion / Re: Boosting the forum population
« on: 20 November 2019, 19:51:40 »
Also I forgot to mention that we can collect tutorials for programming and to discuss about it, to instruct each others. I just saw this topic, guy came with topic about Python and Blender, and experienced people in Python are rare to find https://titanquestfans.net/index.php?topic=1128.0 So if there is will for that, some of us can learn new things from each others.
Second thing, forgot to mention that we have chess on forum, so that can be interesting for some people, league can be created :)
https://titanquestfans.net/index.php?action=chess

299
General Discussion / Re: Boosting the forum population
« on: 20 November 2019, 06:28:19 »
stormyboy, question for you is boosting with?
1. activities and active members around forum that may be players of this game or not at all, or
2. with members that are players of this game

What is important to know is that forum is 99% time in "read only" mode since players are searching for something, but they don't have some special reason to register, nor to post, but with some magic that can be changed. And must say that comparing to some other games we have situation where we can make active community, for that is important to have active content and a lot of activities, not only game related. This thing with expansions means that there is a chance to attract people who can bring activity and ideas.
Old tq.net was based on support and it was more like wiki pages, small place, limited, but here we are almost without limits, so my point is if we put some effort in Offtopic boards, that can bring for sure people who wants to hang out. I mastered that, bringing dead forums to life (note that this forum is very alive, but focused on game only), bringing entertainment, making people to become addicted, but for that I need at least 5 members who would work on my ideas. Ideas are not problem, I can give instructions for some things to happen, atm my problem is time, but with given instructions someone can bring new active members. We can bring here GFX photoshop games, drawing arts, sports betting...

You guys already got few nice ideas, stormyboy you can be admin on facebook page, you can advertise mods there, events on forum, a lot to post every week. Not sure who is using reddit nor what good can come from that since I'm reading there only when I need something. About youtuber he should be invited, he can talk about mods, he can have material for who knows how many videos.
Except topics/posts for discussions, we have 2 live chats, one on forum home page and discord.
Gathering for multiplayer games sounds like a nice idea, if you guys can organize something like that, connection between players, how and where to play together.

300
New Projects / Re: Titan Quest - Titanomachy Mod ( Development )
« on: 19 November 2019, 00:48:15 »
Awesome. Make some screaming sound for this dude so player can feel more uncomfortable in his presence.

Pages: 1 ... 18 19 [20] 21 22 ... 52

SimplePortal 2.3.7 © 2008-2024, SimplePortal